/* ===== AUTH PANEL ===== */

/* Overlay — deckt alles ab */
.auth-overlay {
    position: fixed;
    inset: 0;
    z-index: 2000;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

body.auth-open .auth-overlay {
    pointer-events: all;
}

/* Backdrop — unsichtbar, nur zum Klick-Schließen */
.auth-backdrop {
    position: absolute;
    inset: 0;
}

/* Zentriertes Panel — kommt von rechts rein */
.auth-panel {
    position: relative;
    width: min(460px, 92vw);
    max-height: 90vh;
    background: #111110;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    padding: 40px 36px;
    box-sizing: border-box;
    opacity: 0;
    transform: translateX(120px);
    transition: opacity 0.4s ease, transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

body.auth-open .auth-panel {
    opacity: 1;
    transform: translateX(0);
}

/* Seite komplett nach links rausschieben */
.scroll-container,
.navbar,
.side-nav {
    transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.45s ease;
}

body.auth-open .scroll-container,
body.auth-open .navbar,
body.auth-open .side-nav {
    transform: translateX(-100px);
    opacity: 0;
    pointer-events: none;
}

/* ===== PANEL INHALT ===== */

.auth-close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a1a1aa;
    transition: background 0.2s, color 0.2s;
}

.auth-close-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
}

/* Logo oben */
.auth-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 36px;
}

.auth-logo-icon {
    width: 32px;
    height: 32px;
    background: #f97316;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0c0b09;
    box-shadow: 0 0 12px rgba(249, 115, 22, 0.4);
    flex-shrink: 0;
}

.auth-logo-text {
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

/* Tabs: Register / Login */
.auth-tabs {
    display: flex;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 4px;
    margin-bottom: 32px;
}

.auth-tab {
    flex: 1;
    padding: 10px;
    border: none;
    background: transparent;
    color: #a1a1aa;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: 7px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.auth-tab.active {
    background: #f97316;
    color: #0c0b09;
}

/* Titel */
.auth-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 6px 0;
    letter-spacing: -0.5px;
}

.auth-subtitle {
    font-size: 0.9rem;
    color: #71717a;
    margin: 0 0 28px 0;
}

/* Formular */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.auth-form-section {
    display: none;
    flex-direction: column;
    gap: 16px;
}

.auth-form-section.active {
    display: flex;
}

.auth-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.auth-field label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #a1a1aa;
}

.auth-field input {
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #fff;
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
    width: 100%;
    font-family: inherit;
}

.auth-field input::placeholder {
    color: #52525b;
}

.auth-field input:focus {
    border-color: #f97316;
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.15);
}

/* Submit Button */
.auth-submit-btn {
    width: 100%;
    padding: 13px;
    background: #f97316;
    color: #0c0b09;
    border: none;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s, box-shadow 0.2s, transform 0.1s;
    box-shadow: 0 0 20px rgba(249, 115, 22, 0.3);
    margin-top: 4px;
    font-family: inherit;
}

.auth-submit-btn:hover {
    background: #fb923c;
    box-shadow: 0 0 28px rgba(249, 115, 22, 0.5);
    transform: translateY(-1px);
}

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

.auth-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Trennlinie */
.auth-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 4px 0;
    color: #3f3f46;
    font-size: 0.8rem;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, 0.07);
}

/* Fehler / Erfolg Meldung */
.auth-message {
    padding: 12px 14px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    display: none;
}

.auth-message.error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #f87171;
    display: block;
}

.auth-message.success {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #4ade80;
    display: block;
}

/* Footer Text */
.auth-footer-text {
    font-size: 0.8rem;
    color: #52525b;
    text-align: center;
    margin-top: 20px;
    line-height: 1.5;
}

.auth-footer-text a {
    color: #f97316;
    text-decoration: none;
}

.auth-footer-text a:hover {
    text-decoration: underline;
}
