* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
    color: #e0e0e0;
    min-height: 100vh;
    line-height: 1.6;
}

.header {
    text-align: center;
    padding: 20px;
    border-bottom: 2px solid #4a90e2;
    background: rgba(26, 26, 46, 0.9);
    backdrop-filter: blur(10px);
}

.header h1 {
    color: #4a90e2;
    font-size: 2.5rem;
    font-weight: 300;
    letter-spacing: 3px;
}

.header p {
    color: #a0a0a0;
    margin-top: 10px;
    font-size: 1.1rem;
}

.entity-selector {
    padding: 20px;
    text-align: center;
    background: rgba(15, 15, 35, 0.8);
}

.entity-selector select, .entity-selector input {
    padding: 12px 20px;
    font-size: 1.1rem;
    background: #2a2a40;
    color: #e0e0e0;
    border: 2px solid #4a90e2;
    border-radius: 8px;
    margin: 0 10px;
    min-width: 200px;
}

.main-container {
    display: grid;
    grid-template-columns: 1fr 2fr 1fr;
    gap: 20px;
    padding: 20px;
    max-width: 1600px;
    margin: 0 auto;
}

.panel {
    background: rgba(26, 26, 46, 0.9);
    border: 1px solid #4a90e2;
    border-radius: 12px;
    padding: 20px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.panel h3 {
    color: #4a90e2;
    font-size: 1.4rem;
    margin-bottom: 15px;
    border-bottom: 2px solid #4a90e2;
    padding-bottom: 8px;
}

.section {
    margin-bottom: 25px;
}

.section h4 {
    color: #7bb3f2;
    margin-bottom: 10px;
    font-size: 1.1rem;
}

textarea, input[type="text"], input[type="number"], select {
    width: 100%;
    padding: 10px;
    background: #2a2a40;
    color: #e0e0e0;
    border: 1px solid #4a90e2;
    border-radius: 6px;
    font-size: 0.95rem;
    margin-bottom: 10px;
    resize: vertical;
}

textarea {
    min-height: 80px;
}

.btn {
    background: linear-gradient(135deg, #4a90e2, #357abd);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    margin: 5px;
}

.btn:hover {
    background: linear-gradient(135deg, #357abd, #2968a3);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.3);
}

.btn-danger {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}

.btn-danger:hover {
    background: linear-gradient(135deg, #c0392b, #a93226);
}

.item-list {
    max-height: 400px;
    overflow-y: auto;
    border: 1px solid #4a90e2;
    border-radius: 6px;
    background: rgba(42, 42, 64, 0.5);
}

.item {
    padding: 12px;
    border-bottom: 1px solid #3a3a55;
    cursor: pointer;
    transition: background 0.3s ease;
}

.item:hover {
    background: rgba(74, 144, 226, 0.1);
}

.item:last-child {
    border-bottom: none;
}

.item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
}

.item-score {
    background: #4a90e2;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
}

.item-content {
    color: #d0d0d0;
    font-size: 0.9rem;
    line-height: 1.4;
}

.item-meta {
    color: #a0a0a0;
    font-size: 0.8rem;
    margin-top: 5px;
}

.instructions {
    margin-top: 30px;
    padding: 25px;
    background: rgba(15, 15, 35, 0.9);
    border: 2px solid #4a90e2;
    border-radius: 12px;
}

.instructions h3 {
    color: #4a90e2;
    margin-bottom: 15px;
}

.api-reference {
    background: rgba(42, 42, 64, 0.8);
    padding: 15px;
    border-radius: 8px;
    margin: 15px 0;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
}

.api-endpoint {
    color: #7bb3f2;
    margin: 5px 0;
}

.status-indicator {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 8px;
}

.status-active { background: #27ae60; }
.status-pending { background: #f39c12; }
.status-complete { background: #3498db; }

.loading {
    text-align: center;
    color: #4a90e2;
    font-style: italic;
}

.error {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid #e74c3c;
    color: #e74c3c;
    padding: 10px;
    border-radius: 6px;
    margin: 10px 0;
}

.success {
    background: rgba(39, 174, 96, 0.2);
    border: 1px solid #27ae60;
    color: #27ae60;
    padding: 10px;
    border-radius: 6px;
    margin: 10px 0;
}

/* Navigation Back Button */
.nav-back {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 100;
}

.back-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(74, 144, 226, 0.1);
    border: 1px solid #4a90e2;
    color: #4a90e2;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 8px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    font-size: 0.9rem;
}

.back-btn:hover {
    background: rgba(74, 144, 226, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.3);
    color: #7bb3f2;
}

.back-btn svg {
    width: 18px;
    height: 18px;
}

@media (max-width: 1200px) {
    .main-container {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .nav-back {
        position: relative;
        top: 0;
        left: 0;
        margin-bottom: 10px;
    }
}
