/**
 * bbPress Roleplay Plugin - Frontend Styles
 */

/* Szenen-Liste im Header */
.brp-scenes-header {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 15px;
    margin: 20px 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.brp-scenes-header h3 {
    margin: 0 0 10px 0;
    color: #495057;
    font-size: 18px;
    border-bottom: 2px solid #007cba;
    padding-bottom: 5px;
}

.brp-scenes-header ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.brp-scenes-header li {
    margin: 8px 0;
    padding: 8px 12px;
    background: #ffffff;
    border-radius: 3px;
    border-left: 3px solid #007cba;
    transition: all 0.3s ease;
}

.brp-scenes-header li:hover {
    background: #f1f3f4;
    transform: translateX(5px);
}

.brp-scenes-header a {
    text-decoration: none;
    color: #007cba;
    font-weight: 500;
}

.brp-scenes-header a:hover {
    color: #005a87;
}

.brp-scenes-header .character-name {
    color: #6c757d;
    font-style: italic;
    font-size: 0.9em;
    margin-left: 8px;
}

/* Charakterauswahl in Formularen */
.brp-character-selection {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 15px;
    margin: 15px 0;
}

.brp-character-selection label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #495057;
}

.brp-character-selection select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    background-color: #ffffff;
    font-size: 14px;
    line-height: 1.5;
}

.brp-character-selection select[multiple] {
    height: 120px;
}

.brp-character-selection .description {
    margin: 8px 0 0 0;
    font-size: 13px;
    color: #6c757d;
    font-style: italic;
}

/* Charakter-Avatar */
.brp-character-avatar {
    border-radius: 50%;
    border: 2px solid #007cba;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Benachrichtigungen */
.brp-notice {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 4px;
    padding: 12px 15px;
    margin: 15px 0;
    color: #856404;
}

.brp-notice p {
    margin: 0 0 10px 0;
}

.brp-notice .button {
    background: #007cba;
    color: white;
    padding: 6px 12px;
    text-decoration: none;
    border-radius: 3px;
    font-size: 13px;
}

.brp-notice .button:hover {
    background: #005a87;
    color: white;
}

/* Szenen-Liste (Shortcode) */
.brp-scenes-list {
    background: #ffffff;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 20px;
    margin: 20px 0;
}

.brp-scenes-list h3 {
    margin: 0 0 15px 0;
    color: #495057;
    font-size: 20px;
    border-bottom: 2px solid #007cba;
    padding-bottom: 8px;
}

.brp-scenes-list ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.brp-scenes-list li {
    margin: 10px 0;
    padding: 12px 15px;
    background: #f8f9fa;
    border-radius: 4px;
    border-left: 4px solid #007cba;
    transition: all 0.3s ease;
}

.brp-scenes-list li:hover {
    background: #e9ecef;
    transform: translateX(3px);
}

.brp-scenes-list a {
    text-decoration: none;
    color: #007cba;
    font-weight: 500;
    font-size: 16px;
}

.brp-scenes-list a:hover {
    color: #005a87;
}

.brp-scenes-list .character-name {
    color: #6c757d;
    font-style: italic;
    font-size: 14px;
    margin-left: 10px;
}

/* Charakterverwaltung */
.brp-character-management {
    background: #ffffff;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 20px;
    margin: 20px 0;
}

.brp-character-form {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 20px;
    margin: 20px 0;
}

.brp-character-form .form-group {
    margin-bottom: 15px;
}

.brp-character-form label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
    color: #495057;
}

.brp-character-form input,
.brp-character-form textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 14px;
    line-height: 1.5;
}

.brp-character-form textarea {
    height: 100px;
    resize: vertical;
}

.brp-character-list {
    margin: 20px 0;
}

.brp-character-item {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 15px;
    margin: 10px 0;
    display: flex;
    align-items: center;
    gap: 15px;
}

.brp-character-avatar-small {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 2px solid #007cba;
    object-fit: cover;
}

.brp-character-info {
    flex: 1;
}

.brp-character-info h4 {
    margin: 0 0 5px 0;
    color: #495057;
}

.brp-character-info p {
    margin: 0;
    color: #6c757d;
    font-size: 13px;
}

.brp-character-actions {
    display: flex;
    gap: 8px;
}

.brp-character-actions .button {
    padding: 6px 12px;
    font-size: 12px;
    text-decoration: none;
    border-radius: 3px;
    border: none;
    cursor: pointer;
}

.brp-character-actions .edit {
    background: #007cba;
    color: white;
}

.brp-character-actions .edit:hover {
    background: #005a87;
}

.brp-character-actions .delete {
    background: #dc3545;
    color: white;
}

.brp-character-actions .delete:hover {
    background: #c82333;
}

/* Responsive Design */
@media (max-width: 768px) {
    .brp-scenes-header,
    .brp-character-selection,
    .brp-scenes-list,
    .brp-character-management {
        margin: 10px 0;
        padding: 12px;
    }
    
    .brp-character-item {
        flex-direction: column;
        text-align: center;
    }
    
    .brp-character-actions {
        justify-content: center;
    }
    
    .brp-scenes-header h3,
    .brp-scenes-list h3 {
        font-size: 16px;
    }
}

/* Animationen */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.brp-scenes-header,
.brp-character-selection,
.brp-notice {
    animation: fadeIn 0.3s ease-out;
}

/* bbPress Integration */
.bbp-reply-author .brp-character-avatar,
.bbp-topic-author .brp-character-avatar {
    margin-right: 10px;
}

/* Ladezustand */
.brp-loading {
    opacity: 0.6;
    pointer-events: none;
}

.brp-loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #007cba;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

