/* drama-triangle.css */

.triangle-container-row {
    min-height: 400px;
}

.triangle-wrapper {
    position: relative;
    width: 300px;
    height: 300px;
    margin: 0 auto;
}

.triangle-bg {
    position: absolute;
    top: 50px;
    left: 25px;
    width: 250px;
    height: 250px;
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
    opacity: 0.2;
    z-index: 1;
    transition: opacity 0.3s ease;
}

.drama-bg {
    background-color: var(--bs-danger);
    clip-path: polygon(0% 0%, 100% 0%, 50% 100%);
}

.empowerment-bg {
    background-color: var(--bs-success);
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
}

.role-node {
    position: absolute;
    width: 120px;
    padding: 10px;
    border-radius: 8px;
    background-color: var(--bg-card);
    border: 2px solid rgba(255, 255, 255, 0.2);
    color: var(--text-primary);
    cursor: pointer;
    z-index: 2;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.role-node:hover {
    transform: scale(1.05);
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 6px 12px rgba(0, 240, 255, 0.2);
}

.role-node.active {
    border-color: var(--bs-info);
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.5);
}

/* Drama Triangle Positioning (Points Down) */
/* Top Left */
.persecutor-node {
    top: 0;
    left: -20px;
    border-top: 3px solid var(--bs-danger);
}

/* Top Right */
.rescuer-node {
    top: 0;
    right: -20px;
    border-top: 3px solid var(--bs-warning);
}

/* Bottom Center */
.victim-node {
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    border-bottom: 3px solid var(--bs-secondary);
}
.victim-node:hover {
    transform: translateX(-50%) scale(1.05);
}

/* Empowerment Triangle Positioning (Points Up) */
/* Top Center */
.creator-node {
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    border-top: 3px solid var(--bs-success);
}
.creator-node:hover {
    transform: translateX(-50%) scale(1.05);
}

/* Bottom Left */
.challenger-node {
    bottom: 0;
    left: -20px;
    border-bottom: 3px solid var(--bs-info);
}

/* Bottom Right */
.coach-node {
    bottom: 0;
    right: -20px;
    border-bottom: 3px solid var(--bs-primary);
}

/* Specific pair highlighting */
.highlight-pair .role-node:not(.active-pair) {
    opacity: 0.4;
    filter: grayscale(100%);
}

.highlight-pair .triangle-bg {
    opacity: 0.05;
}

.transform-arrow {
    transition: transform 0.3s ease;
}

@media (max-width: 768px) {
    .triangle-wrapper {
        width: 250px;
        height: 250px;
    }
    
    .triangle-bg {
        width: 200px;
        height: 200px;
        top: 25px;
        left: 25px;
    }
    
    .role-node {
        width: 100px;
        padding: 5px;
        font-size: 0.85rem;
    }
    
    .role-node small {
        font-size: 0.7rem;
    }
    
    .transform-arrow {
        margin: 30px 0;
    }
}

/* Scenario Mode Styles */
.scenario-option {
    cursor: pointer;
    transition: all 0.2s ease;
}

.scenario-option:hover {
    background-color: rgba(255, 255, 255, 0.1) !important;
}

.scenario-option.selected {
    border-color: var(--bs-info) !important;
    background-color: rgba(0, 240, 255, 0.1) !important;
}

.feedback-box {
    animation: fadeIn 0.5s ease-in-out;
}

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