/* ==============================================
   密码验证页面样式文件
   描述：包含全局样式、主面板、密码输入、按钮、管理员面板、提示框等完整样式
   作者：草东
   ============================================== */
/* 版本：1.2
   最后更新：2026.02.26
   核心优化：
   1. 验证成功提示框尺寸优化
   2. 移除提示框顶部高光伪元素所有动效
   3. 代码结构规范化，移除冗余代码
*/

/* ==========================
   1. 全局基础样式 (Global)
   ========================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    height: 100%;
    background: 
        linear-gradient(#121212, transparent 30%),
        repeating-linear-gradient(-70deg, rgba(255, 255, 255, .01), rgba(255, 255, 255, .03) 1.2px, transparent 0, transparent 13px),
        repeating-linear-gradient(20deg, rgba(255, 255, 255, .02), rgba(255, 255, 255, .01) 1.3px, transparent 0, transparent 13px),
        radial-gradient(at bottom, #2c2c2c, #0a0a0a);
    background-size: auto, 28px 38px, 38px 28px, auto;
    background-position: left top, 0 0, 0 0, left top;
    color: #e0e0e0;
    animation: bgMove linear 1.5s infinite;
}

body {
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

a {
    text-decoration: none;
    color: #a0a0a0;
    transition: all 0.3s ease-in-out;
}

a:hover {
    color: #ffffff;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.7);
    transform: translateY(-1px);
}

/* ==========================
   2. 主体容器样式 (Main Container)
   ========================== */
.main-container {
    background: rgba(18, 18, 18, .85) linear-gradient(0deg, rgba(255, 255, 255, .08), transparent 15%);
    border: 1px solid rgba(0, 0, 0, .8);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .1) inset, 0 15px 20px rgba(0, 0, 0, .5);
    border-radius: 2em;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    position: relative;
    text-shadow: 0 -1px 1px #000;
    animation: containerShow 1s ease-out;
    max-width: 460px;
    width: calc(100% - 40px);
    padding: 1.5em 2em 2em;
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    opacity: 1;
    transform: scale(1);
}

/* 主体容器 - 顶部高光伪元素 */
.main-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 1em;
    right: 1em;
    height: 2em;
    border-radius: 9em;
    background: linear-gradient(rgba(255, 255, 255, .25), rgba(255, 255, 255, .05));
    box-shadow: 0 1px 0 rgba(255, 255, 255, .2) inset;
}

/* 主体容器 - 状态样式 */
.main-container.hide {
    opacity: 0;
    transform: scale(0.95);
    pointer-events: none;
}

.main-container.fade {
    opacity: 0.2;
    transform: scale(0.98);
    transition: all 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

/* ==========================
   3. 文本样式 (Typography)
   ========================== */
.title {
    font-size: 1.4em;
    margin-bottom: 1.08em;
}

.desc {
    opacity: .7;
    margin-bottom: 1.5em;
}

/* ==========================
   4. 密码输入框样式 (Password Input)
   ========================== */
.password-container {
    display: flex;
    flex-direction: column;
    gap: 1.5em;
    align-items: stretch;
    margin-bottom: 1.5em;
}

.password-input-group {
    display: flex;
    gap: 0.7em;
    justify-content: center;
}

.password-input {
    width: 2.6em;
    height: 2.6em;
    padding: 0;
    border-radius: 0.7em;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(0, 0, 0, 0.5);
    color: #e0e0e0;
    font-size: 1.05em;
    outline: none;
    transition: all 0.3s ease;
    text-align: center;
    appearance: textfield;
}

/* 隐藏数字输入框增减按钮 */
.password-input::-webkit-outer-spin-button,
.password-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* 输入框聚焦样式 */
.password-input:focus {
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 7px rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

/* 错误抖动效果 */
.password-input-group.shake {
    animation: shake 0.5s cubic-bezier(.36,.07,.19,.97) both;
}

.password-input-group.shake .password-input {
    border-color: #ff6666;
    box-shadow: 0 0 7px rgba(255, 102, 102, 0.3);
}

/* ==========================
   5. 按钮通用样式 (Buttons)
   ========================== */
.btn {
    align-self: center;
    padding: 0.8em 2em;
    border-radius: 1em;
    border: 1px solid rgba(0, 0, 0, .8);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .1) inset, 0 4px 0 rgba(0, 0, 0, 0.3);
    background: rgba(18, 18, 18, .85) linear-gradient(0deg, rgba(255, 255, 255, .08), transparent 15%);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    color: #e0e0e0;
    font-size: 1em;
    text-shadow: 0 -1px 1px #000;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
    transform: translateY(0);
}

/* 按钮 - 顶部高光伪元素 */
.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 1em;
    right: 1em;
    height: 1.2em;
    border-radius: 9em;
    background: linear-gradient(rgba(255, 255, 255, .25), rgba(255, 255, 255, .05));
    box-shadow: 0 1px 0 rgba(255, 255, 255, .2) inset;
    pointer-events: none;
}

/* 按钮 - 交互状态 */
.btn:hover {
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .1) inset, 0 0 8px rgba(255, 255, 255, 0.1), 0 4px 0 rgba(0, 0, 0, 0.3);
    transform: translateY(-1px);
    background: rgba(25, 25, 25, .85) linear-gradient(0deg, rgba(255, 255, 255, .1), transparent 15%);
}

.btn:active:not(:disabled) {
    transform: translateY(2px);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .05) inset, 0 1px 0 rgba(0, 0, 0, 0.3);
    background: rgba(10, 10, 10, .85) linear-gradient(0deg, rgba(255, 255, 255, .05), transparent 15%);
}

.btn:active:not(:disabled)::before {
    height: 0.8em;
    opacity: 0.8;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .05) inset;
}

/* ==========================
   6. 管理员面板样式 (Admin Panel)
   ========================== */
.admin-panel {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.85);
    opacity: 0;
    pointer-events: none;
    background: rgba(18, 18, 18, .9) linear-gradient(0deg, rgba(255, 255, 255, .1), transparent 15%);
    border: 1px solid rgba(0, 0, 0, .9);
    box-shadow: 
        0 0 0 1px rgba(255, 255, 255, .12) inset, 
        0 0 20px rgba(0, 0, 0, .6),
        0 8px 30px rgba(0, 0, 0, .4),
        0 0 10px rgba(100, 100, 150, 0.1) inset;
    border-radius: 2.2em;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    text-shadow: 0 -1px 1px #000;
    z-index: 9999;
    padding: 2em 2em 2.5em;
    min-width: 300px;
    max-width: 400px;
    width: calc(100% - 60px);
    transition: all 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    filter: blur(8px);
}

/* 管理员面板 - 顶部高光伪元素 */
.admin-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 1.5em;
    right: 1.5em;
    height: 2.2em;
    border-radius: 9em;
    background: linear-gradient(rgba(255, 255, 255, .28), rgba(255, 255, 255, .07));
    box-shadow: 0 1px 0 rgba(255, 255, 255, .25) inset;
    pointer-events: none;
    opacity: 0;
    transition: all 0.6s ease 0.2s;
}

/* 管理员面板 - 显示状态 */
.admin-panel.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: all;
    filter: blur(0);
    animation: panelShow 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.admin-panel.show::before {
    opacity: 1;
}

/* 管理员面板 - 标题样式 */
.panel-title {
    font-size: 1.3em;
    text-align: center;
    margin-bottom: 1.8em;
    color: #f0f0f0;
    position: relative;
    padding-bottom: 0.8em;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.6s ease 0.3s;
}

.panel-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 20%;
    right: 20%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
}

.admin-panel.show .panel-title {
    opacity: 1;
    transform: translateY(0);
}

/* 管理员面板 - 输入框组 */
.admin-panel .password-input-group {
    opacity: 0;
    transform: translateY(8px);
    transition: all 0.5s ease 0.4s;
}

.admin-panel.show .password-input-group {
    opacity: 1;
    transform: translateY(0);
}

/* 管理员面板 - 按钮组 */
.admin-panel .btn-group {
    display: flex;
    justify-content: center;
    gap: 1em;
    margin: 1.8em 0 1.5em;
    flex-wrap: wrap;
    opacity: 0;
    transform: translateY(8px);
    transition: all 0.5s ease 0.5s;
}

.admin-panel.show .btn-group {
    opacity: 1;
    transform: translateY(0);
}

/* 管理员面板 - 按钮样式重载 */
.admin-panel .btn {
    padding: 0.8em 1.8em;
    border-radius: 1.2em;
    border: 1px solid rgba(0, 0, 0, .9);
    box-shadow: 
        0 0 0 1px rgba(255, 255, 255, .12) inset, 
        0 4px 0 rgba(0, 0, 0, 0.4),
        0 0 8px rgba(0,0,0,0.2);
    background: rgba(22, 22, 22, .9) linear-gradient(0deg, rgba(255, 255, 255, .1), transparent 20%);
    font-size: 0.95em;
    min-width: 100px;
}

.admin-panel .btn::before {
    height: 1.1em;
}

.admin-panel .btn:hover {
    box-shadow: 
        0 0 0 1px rgba(255, 255, 255, .15) inset, 
        0 0 12px rgba(255, 255, 255, 0.15), 
        0 4px 0 rgba(0, 0, 0, 0.4);
    transform: translateY(-2px);
    background: rgba(28, 28, 28, .9) linear-gradient(0deg, rgba(255, 255, 255, .12), transparent 20%);
}

/* 管理员面板 - MD5结果显示 */
.md5-result {
    font-size: 13px;
    color: #b0b0b0;
    margin: 0 auto;
    word-break: break-all;
    line-height: 1.6;
    padding: 1em 1.2em;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 1em;
    border: 1px solid rgba(255,255,255,0.12);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2) inset;
    max-width: 100%;
    text-align: center;
    opacity: 0;
    transform: translateY(8px);
    transition: all 0.5s ease 0.6s;
}

.admin-panel.show .md5-result {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================
   7. 提示框样式 (Notification Tips)
   ========================== */
/* 7.1 成功提示框（核心优化版） */
.success-tip {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95) translateY(10px);
    background: rgba(18, 18, 18, .85) linear-gradient(0deg, rgba(255, 255, 255, .08), transparent 15%);
    border: 1px solid rgba(0, 0, 0, .8);
    box-shadow: 
        0 0 0 1px rgba(255, 255, 255, .1) inset, 
        0 15px 20px rgba(0, 0, 0, .5);
    border-radius: 2.2em;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    text-shadow: 0 -1px 1px #000;
    padding: 2.2em 2.5em 2.5em;
    max-width: 420px;
    width: calc(100% - 60px);
    color: #e0e0e0;
    font-size: 1.15em;
    text-align: center;
    opacity: 0;
    pointer-events: none;
    transition: all 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 100;
    overflow: hidden;
}

/* 成功提示框 - 顶部高光伪元素（纯静态） */
.success-tip::before {
    content: '';
    position: absolute;
    top: 0;
    left: 1.5em;
    right: 1.5em;
    height: 1.8em;
    border-radius: 9em;
    background: linear-gradient(rgba(255, 255, 255, .28), rgba(255, 255, 255, .07));
    box-shadow: 0 1px 0 rgba(255, 255, 255, .25) inset;
    opacity: 0;
}

/* 成功提示框 - 显示状态 */
.success-tip.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1) translateY(0);
}

.success-tip.show::before {
    opacity: 1;
}

/* 成功提示框 - 文本样式 */
.success-tip span {
    position: relative;
    z-index: 1;
    font-size: 1.45em;
    font-weight: 600;
    display: block;
    margin-bottom: 0.9em;
    color: #e0e0e0;
    text-shadow: 0 -1px 1px #000, 0 0 5px rgba(255,255,255,0.05);
    opacity: 0;
    transform: translateY(15px);
    transition: all 0.7s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.4s;
    animation: textBreath 2s ease-in-out infinite 1.2s;
}

.success-tip .sub-text {
    position: relative;
    z-index: 1;
    font-size: 0.95em;
    opacity: 0.7;
    color: #e0e0e0;
    text-shadow: 0 -1px 1px #000;
    line-height: 1.6;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.7s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.6s;
}

/* 成功提示框 - 省略号加载动效 */
.success-tip .sub-text::after {
    content: '';
    display: inline-block;
    margin-left: 6px;
    width: 24px;
    height: 1em;
    background: radial-gradient(circle, #e0e0e0 2px, transparent 2px);
    background-size: 6px 6px;
    background-repeat: no-repeat;
    background-position: 0 50%, 8px 50%, 16px 50%;
    animation: dotsLoading 1.5s infinite ease-in-out;
}

.success-tip.show span,
.success-tip.show .sub-text {
    opacity: 1;
    transform: translateY(0);
}

/* 7.2 复制提示弹窗 */
.tips-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 1000;
    align-items: flex-end;
}

.copy-tip {
    transform: translate(30px, 15px) scale(0.9);
    opacity: 0;
    background: rgba(22, 22, 22, .9) linear-gradient(0deg, rgba(255, 255, 255, .1), transparent 15%);
    border: 1px solid rgba(0, 0, 0, .9);
    box-shadow: 
        0 0 0 1px rgba(255, 255, 255, .12) inset, 
        0 8px 20px rgba(0, 0, 0, 0.4),
        0 0 10px rgba(100, 100, 150, 0.08) inset;
    border-radius: 1.5em;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    text-shadow: 0 -1px 1px #000;
    padding: 1em 1.8em 1.5em;
    min-width: 180px;
    max-width: 280px;
    color: #e0e0e0;
    font-size: 1em;
    text-align: center;
    pointer-events: none;
    transition: all 0.5s cubic-bezier(0.22, 0.61, 0.36, 1);
    position: relative;
    overflow: hidden;
    animation: tipShow 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

/* 复制提示弹窗 - 顶部高光伪元素 */
.copy-tip::before {
    content: '';
    position: absolute;
    top: 0;
    left: 1em;
    right: 1em;
    height: 1.5em;
    border-radius: 9em;
    background: linear-gradient(rgba(255, 255, 255, .28), rgba(255, 255, 255, .07));
    box-shadow: 0 1px 0 rgba(255, 255, 255, .25) inset;
    transition: all 0.3s ease;
}

/* 复制提示弹窗 - 外发光效果 */
.copy-tip::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 1.5em;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.05);
    pointer-events: none;
    transition: all 0.3s ease;
}

/* 复制提示弹窗 - 隐藏状态 */
.copy-tip.hide {
    animation: tipHide 0.5s cubic-bezier(0.22, 0.61, 0.36, 1) forwards;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .08) inset;
}

/* 复制提示弹窗 - 文本样式 */
.copy-tip span {
    position: relative;
    z-index: 1;
    display: block;
    font-weight: 500;
    margin-bottom: 0.3em;
    animation: textFade 0.6s ease forwards;
    opacity: 0;
}

.copy-tip .tip-content {
    font-size: 0.8em;
    opacity: 0;
    line-height: 1.4;
    animation: textFade 0.6s ease 0.2s forwards;
}

/* ==========================
   8. 备案信息样式 (ICP Footer)
   ========================== */
.icp-footer {
    position: absolute;
    bottom: 1.2em;
    left: 0;
    right: 0;
    text-align: center;
    font-size: 12px;
    opacity: 0.6;
}

/* ==========================
   9. 动画关键帧 (Keyframes)
   ========================== */
/* 背景移动动画 */
@keyframes bgMove {
    0% { background-position: left top, 0 0, 0 0, left top; }
    100% { background-position: left top, 0 78px, 114px 0, left top; }
}

/* 主体容器入场动画 */
@keyframes containerShow {
    0% { transform: scale(1.2); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* 管理员面板入场动画 */
@keyframes panelShow {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.85);
        filter: blur(8px);
    }
    60% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.02);
        filter: blur(0);
    }
    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
        filter: blur(0);
    }
}

/* 错误抖动动画 */
@keyframes shake {
    10%, 90% { transform: translateX(-1px); }
    20%, 80% { transform: translateX(2px); }
    30%, 50%, 70% { transform: translateX(-4px); }
    40%, 60% { transform: translateX(4px); }
}

/* 复制提示弹窗入场/隐藏动画 */
@keyframes tipShow {
    0% { opacity: 0; transform: translate(30px, 15px) scale(0.9); }
    70% { opacity: 1; transform: translate(-5px, -2px) scale(1.05); }
    100% { opacity: 1; transform: translate(0, 0) scale(1); }
}

@keyframes tipHide {
    0% { opacity: 1; transform: translate(0, 0) scale(1); }
    30% { opacity: 1; transform: translate(0, -5px) scale(0.98); }
    100% { opacity: 0; transform: translate(30px, 15px) scale(0.9); }
}

/* 文本渐入动画 */
@keyframes textFade {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 0.7; transform: translateY(0); }
}

/* 成功提示框 - 文字呼吸动效 */
@keyframes textBreath {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
        text-shadow: 0 -1px 1px #000, 0 0 5px rgba(255,255,255,0.05);
    }
    50% {
        opacity: 0.95;
        transform: scale(1.02);
        text-shadow: 0 -1px 1px #000, 0 0 8px rgba(255,255,255,0.1);
    }
}

/* 成功提示框 - 省略号加载动效 */
@keyframes dotsLoading {
    0%, 40%, 80%, 100% { opacity: 0.3; }
    20%, 60% { opacity: 1; }
}