/* ============================================
   LOGIN PAGE STYLES
   Terminal-Style für Login-Seite
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    width: 100%;
    position: fixed;
    overflow: hidden;
}

body {
    background: #000;
    color: #39ff14;
    font-family: 'Menlo', 'Consolas', 'JetBrains Mono', monospace;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
}

.login-screen {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    text-align: center;
    opacity: 0;
    animation: fadeIn 1s ease-in forwards;
    padding: 20px;
}

@keyframes fadeIn {
    to { opacity: 1; }
}

.cursor {
    display: inline-block;
    width: 12px;
    height: 20px;
    background: #39ff14;
    animation: blink 1s infinite;
    margin-bottom: 40px;
    box-shadow: 0 0 20px rgba(57, 255, 20, 0.6);
}

@keyframes blink {
    0%, 49% { opacity: 1; }
    50%, 100% { opacity: 0; }
}

.email-title {
    font-size: 24px;
    margin-bottom: 40px;
    letter-spacing: 1px;
    text-shadow: 0 0 10px #39ff14;
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from { 
        text-shadow: 0 0 10px #39ff14, 0 0 20px #39ff14; 
    }
    to { 
        text-shadow: 0 0 20px #39ff14, 0 0 30px #39ff14, 0 0 40px #39ff14; 
    }
}

.input-group {
    margin-bottom: 30px;
    width: 100%;
    max-width: 400px;
    position: relative;
    animation: slideUp 0.8s ease-out 0.5s backwards;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

input {
    width: 100%;
    padding: 15px 50px 15px 15px;
    background: #000;
    border: 2px solid #39ff14;
    color: #39ff14;
    font-family: inherit;
    font-size: 16px;
    outline: none;
    transition: all 0.3s;
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.3);
}

input:focus {
    box-shadow: 0 0 20px rgba(57, 255, 20, 0.6);
    border-color: #39ff14;
}

input::placeholder {
    color: rgba(57, 255, 20, 0.5);
}

.toggle-password {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    user-select: none;
    width: 24px;
    height: 24px;
    opacity: 0.7;
    transition: all 0.3s;
}

.toggle-password:hover {
    opacity: 1;
    transform: translateY(-50%) scale(1.1);
}

.toggle-password svg {
    width: 100%;
    height: 100%;
    fill: none;
    stroke: #39ff14;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.btn {
    padding: 15px 40px;
    background: #000;
    border: 2px solid #39ff14;
    color: #39ff14;
    font-family: inherit;
    font-size: 16px;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 2px;
    transition: all 0.3s;
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.3);
    animation: slideUp 0.8s ease-out 0.7s backwards;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: #39ff14;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn:hover {
    color: #000;
    box-shadow: 0 0 30px rgba(57, 255, 20, 0.8);
}

.btn span {
    position: relative;
    z-index: 1;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.error-message {
    margin-top: 30px;
    font-size: 18px;
    max-width: 500px;
}

.error-line {
    opacity: 0;
    margin: 10px 0;
    color: #ff3939;
    text-shadow: 0 0 10px #ff3939;
}

.error-line.show {
    animation: errorAppear 0.3s ease-in forwards, shake 0.5s ease-in-out;
}

@keyframes errorAppear {
    to { opacity: 1; }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

/* Mobile Optimization */
@media (max-width: 768px) {
    .email-title {
        font-size: 18px;
    }

    .error-message {
        font-size: 14px;
    }

    .error-line {
        margin: 8px 0;
    }

    .btn {
        padding: 12px 30px;
        font-size: 14px;
    }

    input {
        font-size: 16px;
        padding: 12px 45px 12px 12px;
    }

    .cursor {
        margin-bottom: 30px;
    }

    .input-group {
        margin-bottom: 25px;
    }
}

/* iOS Safari Bottom Bar Fix */
@supports (-webkit-touch-callout: none) {
    body {
        min-height: -webkit-fill-available;
    }
    
    .login-screen {
        min-height: -webkit-fill-available;
    }
}