/* ==========================================
   BEZIEHUNGS-SYSTEM: VOLLSTÄNDIGE KORREKTUR
   ========================================== */

/* Grundgerüst & Scrollbar */
.rel-main-wrapper {
    height: 480px;
    font-size: 15px;
    line-height: 1.7;
    overflow-y: auto;
    padding: 20px;
    color: var(--mittel);
    background: rgba(255, 255, 255, 0.25);
    border-radius: 8px;
    box-sizing: border-box; 
}

.rel-main-title {
    font-family: 'Playfair Display', serif;
    text-align: center;
    color: var(--schrift);
    font-size: 22px;
    text-transform: uppercase;
    margin-bottom: 25px;
    letter-spacing: 2px;
}

/* Kategorien & Spalten */
.rel-column {
    width: 100%;
    margin-bottom: 35px;
    clear: both;
}

.rel-column-head {
    font-family: 'Playfair Display', serif;
    color: var(--schrift);
    font-weight: bold;
    font-size: 18px;
    margin-bottom: 12px;
    border-bottom: 2px solid var(--hell);
    padding-bottom: 5px;
}

/* Die Karten (Full Width & Airy) */
.rel-mini-card {
    display: flex;
    align-items: flex-start;
    gap: 15px; 
    padding: 15px;
    margin-bottom: 15px;
    background: rgba(255, 255, 255, 0.5); 
    border-radius: 12px;
    border: 1px solid #ccc;
    word-break: break-word; /* Verhindert das Ausbrechen von Text */
    transition: all 0.3s ease;
}

.rel-mini-card:hover {
    background: rgba(255, 255, 255, 0.8);
    transform: translateY(-2px);
}

/* Avatar Styling */
.rel-mini-avatar {
    width: 60px;
    height: 60px;
    flex-shrink: 0; /* Verhindert das Quetschen */
    overflow: hidden; /* Sorgt dafür, dass nichts übersteht */
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.rel-mini-avatar img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    display: block;
}

/* Info-Bereich & Textfluss */
.rel-mini-info {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    min-width: 0; /* Wichtig für den Flexbox-Textumbruch */
}

/* Name und Optionen in einer Zeile */
.rel-row-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start; /* Aliniert nach oben, falls Name zweizeilig wird */
    width: 100%;
    gap: 10px;
}

/* Verhindert, dass der Name die Buttons wegdrückt */
.rel-mini-name {
    flex-grow: 1;
    min-width: 0;
    font-weight: bold;
    color: #c0392b;
}

.rel-mini-details {
    font-weight: normal;
    color: #666;
    font-size: 0.85em;
    margin-left: 5px;
}

.rel-mini-options {
    font-size: 0.75em;
    text-align: right;
    flex-shrink: 0; /* Wichtig: Die Buttons dürfen nicht schrumpfen! */
    color: #888;
}

/* Beschreibungstext */
.rel-mini-text {
    font-size: 0.95em;
    color: #444;
    line-height: 1.5;
    font-style: italic;
    margin-top: 5px;
    border-top: 1px solid rgba(0,0,0,0.05);
    padding-top: 5px;
}

/* NPC & Formular Bereich */
.rel-npc-header {
    background: #83a2bd;
    color: #fff;
    text-align: center;
    padding: 12px;
    font-family: 'Segoe UI', sans-serif;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: bold;
    border-radius: 4px;
    margin-bottom: 15px;
}

.rel-npc-grid {
    display: flex;
    gap: 15px;
}

.rel-npc-inputs { 
    flex: 0 0 40%; 
    display: flex; 
    flex-direction: column; 
    gap: 8px; 
}

.rel-npc-desc { 
    flex: 1; 
}

.rel-npc-desc textarea {
    width: 100%;
    height: 100%;
    min-height: 160px;
    border: 1px solid #ccc;
    background: #f9f9f9;
    padding: 10px;
    border-radius: 4px;
    resize: vertical;
}

.rel-npc-button {
    background: #83a2bd;
    color: white;
    border: none;
    padding: 12px;
    width: 100%;
    margin-top: 15px;
    cursor: pointer;
    text-transform: uppercase;
    font-weight: bold;
    border-radius: 4px;
}
.rel-form-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.rel-form-container {
    margin-top: 40px; /* Erhöht den Abstand nach oben */
    background: rgba(255, 255, 255, 0.3);
    padding: 20px;
    border-radius: 15px;
    border: 1px dashed #f2d7d5;
}
.rel-form-row-top {
    display: flex;
    gap: 10px;
}

.rel-form-row-top input, 
.rel-form-row-top select {
    flex: 1;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.rel-form-grid textarea {
    width: 100%;
    height: 80px;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    resize: vertical;
    box-sizing: border-box;
}

.rel-button {
    background: #83a2bd;
    color: #fff;
    border: none;
    padding: 10px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    text-transform: uppercase;
}