/* ============ 密码门禁 ============ */
body.gate-locked {
    overflow: hidden;
}

.gate-screen {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(ellipse at center, rgba(20, 34, 22, 0.96), rgba(3, 6, 4, 0.995));
    backdrop-filter: blur(12px);
    transition: opacity 0.3s ease;
}

.gate-screen.gate-hidden {
    opacity: 0;
    pointer-events: none;
}

.gate-card {
    width: min(380px, calc(100vw - 48px));
    padding: 44px 36px 36px;
    border: 1px solid rgba(164, 230, 111, 0.18);
    border-radius: 20px;
    background: linear-gradient(165deg, rgba(24, 34, 27, 0.95), rgba(10, 16, 12, 0.98));
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(164, 230, 111, 0.05);
    text-align: center;
}

.gate-logo {
    font-size: 44px;
    margin-bottom: 8px;
    filter: drop-shadow(0 0 20px rgba(164, 230, 111, 0.3));
}

.gate-card h2 {
    margin: 12px 0 6px;
    font-size: 22px;
    letter-spacing: -0.02em;
}

.gate-sub {
    margin: 0;
    color: #95a298;
    font-size: 12px;
    line-height: 1.8;
}

.gate-form {
    display: flex;
    gap: 8px;
    margin-top: 24px;
}

.gate-input {
    width: 100%;
    flex: 1;
    padding: 12px 14px;
    border: 1px solid var(--line-strong);
    border-radius: 10px;
    background: rgba(5, 10, 7, 0.8);
    color: #e8f0ea;
    font-size: 14px;
    font-family: var(--mono, Consolas, monospace);
    letter-spacing: 0.12em;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.gate-input-wrap {
    position: relative;
    flex: 1;
}

.gate-input-wrap .gate-input {
    padding-right: 44px;
}

.gate-toggle {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: #7b8a7d;
    cursor: pointer;
    transition: color 0.2s, background 0.2s;
}

.gate-toggle:hover {
    color: #dfe7df;
    background: rgba(164, 230, 111, 0.08);
}

.gate-toggle .eye,
.gate-toggle .eye-off {
    display: none;
}

.gate-toggle .eye-off {
    display: block;
}

.gate-input[type="text"] ~ .gate-toggle .eye {
    display: block;
}

.gate-input[type="text"] ~ .gate-toggle .eye-off {
    display: none;
}

.gate-input:focus {
    border-color: rgba(164, 230, 111, 0.5);
    box-shadow: 0 0 0 3px rgba(164, 230, 111, 0.12);
}

.gate-input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.gate-submit {
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, #a4e66f, #6bc043);
    color: #111;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
}

.gate-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(164, 230, 111, 0.3);
}

.gate-submit:active {
    transform: translateY(0);
}

.gate-msg {
    margin-top: 14px;
    color: #95a298;
    font-size: 12px;
    min-height: 18px;
    line-height: 1.6;
}

.gate-msg.gate-error {
    color: #ff7e72;
}

.gate-hint {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px dashed rgba(218, 238, 220, 0.08);
    color: #768079;
    font-size: 11px;
}
