/* GreenShadow - Profil-Management CSS v5.0 */
/* Erweiterte Styles für das neue Profil-System */

/* Profil-Button Styles - GELB/ORANGE VERSION */
.profile-button {
    background: linear-gradient(45deg, #f59e0b, #d97706) !important;
    color: white !important;
    border: none !important;
    border-radius: 25px !important;
    padding: 0.5rem 1.5rem !important;
    font-size: 0.9rem !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3) !important;
    display: flex !important;
    align-items: center !important;
    gap: 0.5rem !important;
    position: relative !important;
    overflow: hidden !important;
}

.profile-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.profile-button:hover::before {
    left: 100%;
}

.profile-button:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 6px 25px rgba(245, 158, 11, 0.5);
    background: linear-gradient(45deg, #fbbf24, #f59e0b) !important;
}

.profile-button:active {
    transform: translateY(0) scale(1);
}

/* Temp-Login Button mit Pulsing-Animation */
.temp-login-button {
    background: linear-gradient(45deg, #f59e0b, #d97706) !important;
    animation: pulse 2s infinite !important;
}

@keyframes pulse {
    0% { 
        opacity: 1; 
        transform: scale(1); 
        box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
    }
    50% { 
        opacity: 0.8; 
        transform: scale(1.05); 
        box-shadow: 0 6px 25px rgba(245, 158, 11, 0.6);
    }
    100% { 
        opacity: 1; 
        transform: scale(1); 
        box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
    }
}

/* Alternative: Logout-Button Klasse für eindeutige Identifikation */
.logout-button.profile-button {
    background: linear-gradient(45deg, #f59e0b, #d97706) !important;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3) !important;
}

.logout-button.profile-button:hover {
    background: linear-gradient(45deg, #fbbf24, #f59e0b) !important;
    box-shadow: 0 6px 25px rgba(245, 158, 11, 0.5) !important;
}

/* KRITISCH: Verstecke Profil-Buttons im Splash Screen */
.splash-screen .profile-button,
.splash-screen .logout-button {
    display: none !important;
    visibility: hidden !important;
}

/* KRITISCHER FIX: Logo-Glow Element - das pulsierende orange Viereck */
.splash-screen .logo-glow,
.splash-active .logo-glow,
.logo-glow {
    background: radial-gradient(circle, rgba(34, 197, 94, 0.3), transparent 70%) !important;
    background-color: transparent !important;
    /* NOTFALL: Falls es trotzdem orange wird, verstecken */
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
}

/* Nur für den Fall dass das logo-glow Element doch benötigt wird */
.splash-screen .logo-container .logo-glow {
    background: radial-gradient(circle, rgba(34, 197, 94, 0.2), transparent 70%) !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* NUCLEAR OPTION: VERSTECKE ALLES ORANGE/GELB WÄHREND SPLASH SCREEN */
.splash-screen *,
.splash-active * {
    /* Überschreibe alle orange/gelb Farben während Splash Screen */
    background: none !important;
}

/* JAVASCRIPT-ÜBERSCHREIBUNG: Alle dynamisch erstellten orange Buttons verstecken */
.splash-active button[style*="f59e0b"],
.splash-active button[style*="d97706"],
.splash-active button[style*="245, 158, 11"],
.splash-active button[style*="217, 119, 6"],
.splash-active .temp-login-button,
.splash-active .logout-button[style*="orange"],
.splash-active .logout-button[style*="f59e0b"],
.splash-active *[style*="linear-gradient(45deg, #f59e0b"] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
    width: 0 !important;
    height: 0 !important;
    pointer-events: none !important;
    z-index: -9999 !important;
}

/* Nur grüne Elemente erlauben */
.splash-screen .start-button {
    background: linear-gradient(45deg, #22c55e, #16a34a) !important;
}

.splash-screen .logo {
    color: #22c55e !important;
}

/* VERSTECKE ALLE BUTTONS außer start-button */
.splash-screen button:not(.start-button),
.splash-active button:not(.start-button) {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

/* VERSTECKE TOPBAR komplett */
.splash-active .topbar,
.splash-screen .topbar {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
}

/* VERSTECKE alle Elemente mit orange/gelb Farben */
.splash-active *[style*="f59e0b"],
.splash-active *[style*="d97706"],
.splash-active *[style*="fbbf24"],
.splash-active *[style*="orange"],
.splash-active *[style*="yellow"],
.splash-screen *[style*="f59e0b"],
.splash-screen *[style*="d97706"],
.splash-screen *[style*="fbbf24"],
.splash-screen *[style*="orange"],
.splash-screen *[style*="yellow"] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
}

/* VERSTECKE alle Klassen mit orange/gelb */
.splash-active .profile-button,
.splash-active .logout-button,
.splash-active .login-button,
.splash-active .temp-login-button,
.splash-screen .profile-button,
.splash-screen .logout-button,
.splash-screen .login-button,
.splash-screen .temp-login-button {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    pointer-events: none !important;
}

/* Profil-Modal Styles */
#profileModal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(15px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

#profileModal.active {
    opacity: 1;
    visibility: visible;
}

#profileModal .modal-content {
    background: linear-gradient(135deg, rgba(25, 25, 25, 0.95), rgba(35, 35, 35, 0.9));
    border: 2px solid rgba(34, 197, 94, 0.4);
    border-radius: 20px;
    padding: 2.5rem;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    transform: translateY(50px) scale(0.9);
    transition: transform 0.3s ease;
    backdrop-filter: blur(20px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6), 0 0 50px rgba(34, 197, 94, 0.2);
}

#profileModal.active .modal-content {
    transform: translateY(0) scale(1);
}

/* Profil-Info Bereich */
.profile-info {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: 12px;
    padding: 1.5rem;
    margin: 1rem 0;
    position: relative;
    overflow: hidden;
}

.profile-info::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(34, 197, 94, 0.1), transparent);
    transition: left 2s ease;
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    50% { left: 100%; }
    100% { left: 100%; }
}

.profile-info h4 {
    color: #22c55e;
    margin: 0 0 1rem 0;
    font-size: 1.1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-grid {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.5rem 1rem;
    font-size: 0.9rem;
}

.info-grid span:nth-child(odd) {
    color: #a3a3a3;
    font-weight: 500;
}

.info-grid span:nth-child(even) {
    color: #e0e0e0;
    font-weight: 600;
}

/* Form-Sections */
.form-section {
    background: rgba(25, 25, 25, 0.6);
    border: 1px solid rgba(60, 60, 60, 0.3);
    border-radius: 12px;
    padding: 1.5rem;
    margin: 1.5rem 0;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.form-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, #22c55e, #16a34a);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.form-section:hover {
    background: rgba(25, 25, 25, 0.8);
    border-color: rgba(34, 197, 94, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.form-section:hover::before {
    transform: scaleY(1);
}

.form-section h4 {
    color: #22c55e;
    margin: 0 0 1rem 0;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Profil-Form Inputs */
.profile-form .form-group {
    margin-bottom: 1rem;
}

.profile-form .form-group label {
    display: block;
    color: #e0e0e0;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.profile-form .form-group input {
    width: 100%;
    padding: 0.8rem;
    background: rgba(40, 40, 40, 0.8);
    border: 1px solid rgba(60, 60, 60, 0.5);
    border-radius: 8px;
    color: #e0e0e0;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.profile-form .form-group input:focus {
    outline: none;
    border-color: #22c55e;
    box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.2);
    background: rgba(50, 50, 50, 0.9);
    transform: translateY(-1px);
}

.profile-form .form-group input:hover {
    border-color: rgba(34, 197, 94, 0.4);
}

.profile-form .form-group small {
    display: block;
    color: #a3a3a3;
    font-size: 0.8rem;
    margin-top: 0.5rem;
    line-height: 1.4;
}

/* Update-Buttons */
.update-email-btn,
.update-password-btn {
    width: 100%;
    padding: 0.8rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 0.5rem;
    font-size: 0.9rem;
    position: relative;
    overflow: hidden;
}

.update-email-btn {
    background: linear-gradient(45deg, #3b82f6, #2563eb);
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.update-email-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(59, 130, 246, 0.5);
}

.update-password-btn {
    background: linear-gradient(45deg, #f59e0b, #d97706);
    color: white;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.update-password-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(245, 158, 11, 0.5);
}

/* Button-Ripple-Effect */
.update-email-btn::before,
.update-password-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.update-email-btn:hover::before,
.update-password-btn:hover::before {
    left: 100%;
}

/* Passwort-Match Indikator */
#profile-password-match {
    margin-top: 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

/* Form-Actions */
.form-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.logout-btn,
.close-profile-btn {
    flex: 1;
    padding: 1rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    position: relative;
    overflow: hidden;
}

.logout-btn {
    background: linear-gradient(45deg, #ef4444, #dc2626);
    color: white;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.logout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(239, 68, 68, 0.5);
}

.close-profile-btn {
    background: rgba(60, 60, 60, 0.5);
    color: #e0e0e0;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.close-profile-btn:hover {
    background: rgba(34, 197, 94, 0.1);
    border-color: rgba(34, 197, 94, 0.5);
    transform: translateY(-2px);
}

/* Modal-Animations */
@keyframes slideInRight {
    from { 
        opacity: 0; 
        transform: translateX(100px); 
    }
    to { 
        opacity: 1; 
        transform: translateX(0); 
    }
}

/* Loading-State für Buttons */
.update-email-btn:disabled,
.update-password-btn:disabled,
.logout-btn:disabled,
.close-profile-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* Success/Error States */
.form-group input.success {
    border-color: #22c55e;
    box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.2);
}

.form-group input.error {
    border-color: #ef4444;
    box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.2);
}

/* Mobile Responsive für Profil-Modal */
@media (max-width: 768px) {
    #profileModal .modal-content {
        margin: 1rem;
        padding: 1.5rem;
        max-height: 95vh;
        max-width: none;
        width: calc(100vw - 2rem);
    }
    
    .info-grid {
        grid-template-columns: 1fr;
        gap: 0.3rem;
    }
    
    .info-grid span:nth-child(odd) {
        font-size: 0.8rem;
        margin-bottom: 0.2rem;
    }
    
    .info-grid span:nth-child(even) {
        font-size: 0.9rem;
        margin-bottom: 0.8rem;
        padding-left: 1rem;
    }
    
    .form-actions {
        flex-direction: column;
        gap: 0.8rem;
    }
    
    .profile-info h4,
    .form-section h4 {
        font-size: 0.95rem;
    }
    
    .profile-button {
        padding: 0.4rem 1.2rem !important;
        font-size: 0.85rem !important;
        gap: 0.3rem !important;
    }
}

/* Tablet Responsive */
@media (max-width: 1024px) and (min-width: 769px) {
    .profile-button {
        padding: 0.45rem 1.3rem !important;
        font-size: 0.88rem !important;
    }
}

/* Smooth Transitions für alle Profil-Elemente */
.profile-button,
.profile-info,
.form-section,
.update-email-btn,
.update-password-btn,
.logout-btn,
.close-profile-btn,
#profile-password-match {
    will-change: transform, opacity;
}

/* Custom Scrollbar für Profil-Modal */
#profileModal .modal-content::-webkit-scrollbar {
    width: 8px;
}

#profileModal .modal-content::-webkit-scrollbar-track {
    background: rgba(60, 60, 60, 0.3);
    border-radius: 4px;
}

#profileModal .modal-content::-webkit-scrollbar-thumb {
    background: rgba(34, 197, 94, 0.5);
    border-radius: 4px;
}

#profileModal .modal-content::-webkit-scrollbar-thumb:hover {
    background: rgba(34, 197, 94, 0.7);
}

/* Enhanced Focus Styles */
.profile-form input:focus-visible,
.update-email-btn:focus-visible,
.update-password-btn:focus-visible,
.logout-btn:focus-visible,
.close-profile-btn:focus-visible,
.profile-button:focus-visible {
    outline: 2px solid #f59e0b;
    outline-offset: 2px;
}

/* Status Indicators */
.email-status {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 0.5rem;
}

.email-status.verified {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.email-status.unverified {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.email-status.pending {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
}

/* Profile Header mit Gradient */
.profile-header {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.1), rgba(16, 163, 74, 0.1));
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 1.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.profile-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, #22c55e, #16a34a, #22c55e);
    animation: gradient-flow 3s ease-in-out infinite;
}

@keyframes gradient-flow {
    0%, 100% { 
        background-position: 0% 50%; 
    }
    50% { 
        background-position: 100% 50%; 
    }
}