/* peteITcms Account Plugin Styles */

/* Container und Layout */
.peteitcms-account-form-wrapper {
    max-width: 400px;
    margin: 0 auto;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
}

.peteitcms-account-form-wrapper h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
    font-size: 24px;
}

/* Formular-Gruppen */
.peteitcms-account-form-group {
    margin-bottom: 20px;
}

.peteitcms-account-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #555;
    font-size: 14px;
}

.peteitcms-account-form-group input[type="text"],
.peteitcms-account-form-group input[type="email"],
.peteitcms-account-form-group input[type="password"],
.peteitcms-account-form-group input[type="date"],
.peteitcms-account-form-group select,
.peteitcms-account-form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    box-sizing: border-box;
    transition: border-color 0.3s ease;
}

/* Modern File Upload - verstecke Default Input */
.peteitcms-account-form-group input[type="file"] {
    display: none;
}

/* Custom File Upload Wrapper */
.peteitcms-account-file-upload-wrapper {
    position: relative;
    width: 100%;
}

.peteitcms-account-file-upload-area {
    position: relative;
    width: 100%;
    padding: 30px 20px;
    border: 2px dashed #ddd;
    border-radius: 8px;
    background: linear-gradient(145deg, #f8f9fa 0%, #ffffff 100%);
    text-align: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.peteitcms-account-file-upload-area::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    transition: left 0.6s;
}

.peteitcms-account-file-upload-area:hover::before {
    left: 100%;
}

.peteitcms-account-file-upload-area:hover {
    border-color: #f67b56;
    background: linear-gradient(145deg, #fff5f3 0%, #ffffff 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(246, 123, 86, 0.1);
}

.peteitcms-account-file-upload-area.dragover {
    border-color: #5686FF;
    background: linear-gradient(145deg, #f0f4ff 0%, #ffffff 100%);
    transform: scale(1.01);
}

.peteitcms-account-file-upload-content {
    position: relative;
    z-index: 5;
}

.peteitcms-account-file-upload-icon {
    font-size: 32px;
    color: #f67b56;
    margin-bottom: 10px;
    display: block;
    transition: all 0.3s ease;
}

.peteitcms-account-file-upload-area:hover .peteitcms-account-file-upload-icon {
    color: #5686FF;
    transform: scale(1.1);
}

.peteitcms-account-file-upload-text {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.peteitcms-account-file-upload-hint {
    font-size: 12px;
    color: #666;
}

.peteitcms-account-form-group input:focus,
.peteitcms-account-form-group select:focus,
.peteitcms-account-form-group textarea:focus {
    outline: none;
    border-color: #f67b56;
    box-shadow: 0 0 0 2px rgba(246, 123, 86, 0.1);
}

.peteitcms-account-form-group textarea {
    resize: vertical;
    min-height: 80px;
}

/* Checkbox und Radio Buttons */
.peteitcms-account-form-group input[type="checkbox"],
.peteitcms-account-form-group input[type="radio"] {
    width: auto;
    margin-right: 8px;
}

.peteitcms-account-form-group label input[type="checkbox"],
.peteitcms-account-form-group label input[type="radio"] {
    margin-right: 8px;
}

/* Submit Button */
.peteitcms-account-submit-btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(290deg,#5686FF 0%,#f67b56 100%);
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.peteitcms-account-submit-btn:hover {
    background: #f67b56;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(246, 123, 86, 0.3);
}

.peteitcms-account-submit-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Links */
.peteitcms-account-form-links {
    text-align: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.peteitcms-account-form-links a {
    color: #f67b56;
    text-decoration: none;
    font-size: 14px;
    margin: 0 10px;
    transition: color 0.3s ease;
}

.peteitcms-account-form-links a:hover {
    color: #5686FF;
    text-decoration: underline;
}

/* Nachrichten */
.peteitcms-account-messages {
    margin-top: 15px;
}

.peteitcms-account-message {
    padding: 12px;
    border-radius: 4px;
    margin-bottom: 10px;
    font-size: 14px;
}

.peteitcms-account-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.peteitcms-account-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.peteitcms-account-message.info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.peteitcms-account-message.warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

/* Avatar Upload */
.peteitcms-account-avatar-section {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.peteitcms-account-current-avatar {
    margin-bottom: 15px;
}

.peteitcms-account-avatar {
    border-radius: 50%;
    border: 3px solid #f67b56;
    display: inline-block;
    transition: border-color 0.3s ease;
}

.peteitcms-account-avatar:hover {
    border-color: #5686FF;
}

.peteitcms-account-avatar-upload {
    position: relative;
    display: inline-block;
    width: 100%;
    max-width: 300px;
    margin: 15px 0;
}

/* Modern Drag & Drop Upload Area für Avatar */
.peteitcms-account-upload-area {
    position: relative;
    width: 100%;
    padding: 40px 20px;
    border: 2px dashed #ddd;
    border-radius: 12px;
    background: linear-gradient(145deg, #f8f9fa 0%, #ffffff 100%);
    text-align: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.peteitcms-account-upload-area::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    transition: left 0.6s;
}

.peteitcms-account-upload-area:hover::before {
    left: 100%;
}

.peteitcms-account-upload-area:hover {
    border-color: #f67b56;
    background: linear-gradient(145deg, #fff5f3 0%, #ffffff 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(246, 123, 86, 0.15);
}

.peteitcms-account-upload-area.dragover {
    border-color: #5686FF;
    background: linear-gradient(145deg, #f0f4ff 0%, #ffffff 100%);
    transform: scale(1.02);
}

.peteitcms-account-avatar-upload input[type="file"] {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 10;
}

.peteitcms-account-upload-content {
    position: relative;
    z-index: 5;
}

.peteitcms-account-upload-icon {
    font-size: 48px;
    color: #f67b56;
    margin-bottom: 15px;
    display: block;
    transition: all 0.3s ease;
}

.peteitcms-account-upload-area:hover .peteitcms-account-upload-icon {
    color: #5686FF;
    transform: scale(1.1);
}

.peteitcms-account-upload-text {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.peteitcms-account-upload-hint {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
}

.peteitcms-account-avatar-upload-btn {
    display: inline-block;
    padding: 12px 24px;
    background: linear-gradient(290deg,#5686FF 0%,#f67b56 100%);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.peteitcms-account-avatar-upload-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.6s;
}

.peteitcms-account-avatar-upload-btn:hover::before {
    left: 100%;
}

.peteitcms-account-avatar-upload-btn:hover {
    background: linear-gradient(290deg,#4a73e6 0%,#e55a3d 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(246, 123, 86, 0.4);
}

.peteitcms-account-avatar-upload-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(246, 123, 86, 0.3);
}

/* Upload Progress */
.peteitcms-account-upload-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(290deg,#5686FF 0%,#f67b56 100%);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 0 0 12px 12px;
}

.peteitcms-account-upload-progress.active {
    animation: progress-pulse 1.5s ease-in-out infinite;
}

@keyframes progress-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* File Preview */
.peteitcms-account-file-preview {
    display: none;
    margin-top: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #f67b56;
}

.peteitcms-account-file-preview.show {
    display: block;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.peteitcms-account-file-preview-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.peteitcms-account-file-preview-icon {
    width: 32px;
    height: 32px;
    background: linear-gradient(290deg,#5686FF 0%,#f67b56 100%);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 14px;
}

.peteitcms-account-file-preview-info {
    flex: 1;
}

.peteitcms-account-file-preview-name {
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.peteitcms-account-file-preview-size {
    color: #666;
    font-size: 12px;
}

/* Profil-Bereiche */
.peteitcms-account-profile-section,
.peteitcms-account-password-section {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.peteitcms-account-profile-section:last-child,
.peteitcms-account-password-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.peteitcms-account-profile-section h3,
.peteitcms-account-password-section h3 {
    margin-bottom: 15px;
    color: #333;
    font-size: 18px;
    border-bottom: 2px solid #f67b56;
    padding-bottom: 5px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .peteitcms-account-form-wrapper {
        margin: 10px;
        padding: 15px;
        border-radius: 4px;
    }
    
    .peteitcms-account-form-group input,
    .peteitcms-account-form-group select,
    .peteitcms-account-form-group textarea {
        padding: 10px;
    }
    
    .peteitcms-account-submit-btn {
        padding: 10px;
        font-size: 14px;
    }
}

/* Loading States */
.peteitcms-account-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.6;
}

.peteitcms-account-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #f67b56;
    border-radius: 50%;
    animation: fl-spin 1s linear infinite;
}

@keyframes fl-spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Form Switching (für Login/Register Toggle) */
.peteitcms-account-form-container {
    position: relative;
}

.peteitcms-account-form-container .peteitcms-account-form-wrapper {
    display: block;
}

.peteitcms-account-form-container .peteitcms-account-form-wrapper.peteitcms-account-hidden {
    display: none;
}

/* Logout Link */
.peteitcms-account-logout-link {
    display: inline-block;
    padding: 8px 15px;
    background: #dc3545;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    transition: background-color 0.3s ease;
}

.peteitcms-account-logout-link:hover {
    background: #c82333;
    color: white;
    text-decoration: none;
}

/* Tabs für Profil */
.peteitcms-account-profile-tabs {
    display: flex;
    border-bottom: 1px solid #ddd;
    margin-bottom: 20px;
}

.peteitcms-account-profile-tab {
    padding: 10px 20px;
    background: #f7f7f7;
    border: 1px solid #ddd;
    border-bottom: none;
    cursor: pointer;
    margin-right: 5px;
    border-radius: 4px 4px 0 0;
    color: #666;
    text-decoration: none;
}

.peteitcms-account-profile-tab.active {
    background: white;
    color: #333;
    border-bottom: 1px solid white;
    position: relative;
    z-index: 1;
}

.peteitcms-account-profile-tab:hover {
    background: #e7e7e7;
    text-decoration: none;
}

/* Benutzerprofil Anzeige */
.peteitcms-account-user-profile {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.peteitcms-account-user-profile-header {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.peteitcms-account-user-profile-avatar {
    margin-bottom: 10px;
}

.peteitcms-account-user-profile-name {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.peteitcms-account-user-profile-role {
    color: #666;
    font-size: 14px;
}

.peteitcms-account-user-profile-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.peteitcms-account-info-group {
    margin-bottom: 15px;
}

.peteitcms-account-info-label {
    font-weight: 600;
    color: #555;
    margin-bottom: 5px;
}

.peteitcms-account-info-value {
    color: #333;
}

/* Eingeloggte Benutzer Anzeige */
.peteitcms-account-logged-in-info {
    max-width: 400px;
    margin: 0 auto;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    text-align: center;
}

.peteitcms-account-logged-in-info p {
    margin-bottom: 20px;
    font-size: 16px;
    color: #495057;
}

.peteitcms-account-user-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Button-Styles */
.peteitcms-account-btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    min-width: 120px;
}

.peteitcms-account-btn-primary {
    background: linear-gradient(290deg,#5686FF 0%,#f67b56 100%);
    color: white;
}

.peteitcms-account-btn-primary:hover {
    background: #f67b56;
    color: white;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(246, 123, 86, 0.3);
}

.peteitcms-account-btn-secondary {
    background: #6c757d;
    color: white;
}

.peteitcms-account-btn-secondary:hover {
    background: #545b62;
    color: white;
    text-decoration: none;
}

/* Responsive Design für User Actions */
@media (max-width: 480px) {
    .peteitcms-account-user-actions {
        flex-direction: column;
    }
    
    .peteitcms-account-btn {
        width: 100%;
        margin-bottom: 10px;
    }
}

/* User Info Shortcode */
.peteitcms-account-user-info {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 4px;
    border: 1px solid #e9ecef;
}

.peteitcms-account-user-avatar img {
    border-radius: 50%;
    display: block;
}

.peteitcms-account-user-name {
    font-weight: 600;
    color: #495057;
}

.peteitcms-account-user-links {
    margin-left: auto;
    display: flex;
    gap: 10px;
}

.peteitcms-account-user-links a {
    padding: 5px 10px;
    border-radius: 3px;
    text-decoration: none;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.peteitcms-account-profile-link {
    background: linear-gradient(290deg,#5686FF 0%,#f67b56 100%);
    color: white;
}

.peteitcms-account-profile-link:hover {
    background: #f67b56;
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(246, 123, 86, 0.3);
}

.peteitcms-account-logout-link {
    background: #dc3545;
    color: white;
}

.peteitcms-account-logout-link:hover {
    background: #c82333;
    color: white;
    text-decoration: none;
}

.peteitcms-account-not-logged-in {
    padding: 10px;
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 4px;
    color: #856404;
}

.peteitcms-account-not-logged-in a {
    color: #f67b56;
    text-decoration: none;
    font-weight: 600;
}

.peteitcms-account-not-logged-in a:hover {
    color: #5686FF;
    text-decoration: underline;
}

/* Responsive Design für User Info */
@media (max-width: 480px) {
    .peteitcms-account-user-info {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .peteitcms-account-user-links {
        margin-left: 0;
        justify-content: center;
    }
}

/* Logout-Bestätigung */
.peteitcms-account-logout-message {
    max-width: 400px;
    margin: 0 auto 20px auto;
    padding: 15px;
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
    color: #155724;
    text-align: center;
}

.peteitcms-account-logout-message p {
    margin: 0;
    font-weight: 500;
}

/* Logout-Bestätigung */
.peteitcms-account-logout-confirmation {
    max-width: 400px;
    margin: 0 auto;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.peteitcms-account-logout-confirmation p {
    margin-bottom: 20px;
    font-size: 16px;
    color: #495057;
}

.peteitcms-account-logout-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.peteitcms-account-btn-danger {
    background: #dc3545;
    color: white;
}

.peteitcms-account-btn-danger:hover {
    background: #c82333;
    color: white;
    text-decoration: none;
}

/* Responsive Design für Logout-Bestätigung */
@media (max-width: 480px) {
    .peteitcms-account-logout-actions {
        flex-direction: column;
    }
    
    .peteitcms-account-logout-actions .peteitcms-account-btn {
        width: 100%;
        margin-bottom: 10px;
    }
}

/* Utilities */
.peteitcms-account-text-center {
    text-align: center;
}

.peteitcms-account-text-left {
    text-align: left;
}

.peteitcms-account-text-right {
    text-align: right;
}

.peteitcms-account-hidden {
    display: none !important;
}

.peteitcms-account-visible {
    display: block !important;
}

.peteitcms-account-clearfix::after {
    content: "";
    display: table;
    clear: both;
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .peteitcms-account-form-wrapper {
        background: #2c3e50;
        color: #ecf0f1;
    }
    
    .peteitcms-account-form-group input,
    .peteitcms-account-form-group select,
    .peteitcms-account-form-group textarea {
        background: #34495e;
        border-color: #4a5f7a;
        color: #ecf0f1;
    }
    
    .peteitcms-account-form-group label {
        color: #bdc3c7;
    }
    
    .peteitcms-account-user-profile {
        background: #2c3e50;
        color: #ecf0f1;
    }
}
