:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --success-color: #27ae60;
    --warning-color: #f39c12;
    --danger-color: #e74c3c;
    --dark-color: #12171c;
}

body {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    min-height: 100vh;
}

.navbar {
    background: var(--dark-color) !important;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.navbar-brand img {
    height: 40px;
}

.main-container {
    margin-top: 2rem;
    margin-bottom: 2rem;
}

.config-header {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-align: center;
}

.config-header h1 {
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.config-header p {
    color: #666;
    font-size: 1.1rem;
    margin-bottom: 0;
}

.endpoint-card {
    background: white;
    border-radius: 15px;
    margin-bottom: 1.5rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    overflow: hidden;
}

.endpoint-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.endpoint-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 1.5rem;
    cursor: pointer;
    position: relative;
}

.endpoint-header h5 {
    margin: 0;
    font-weight: 600;
    font-size: 1.2rem;
}

.endpoint-path {
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    opacity: 0.9;
    margin-top: 0.5rem;
}

.collapse-icon {
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    transition: transform 0.3s ease;
    font-size: 1.2rem;
}

.collapse-icon.rotated {
    transform: translateY(-50%) rotate(180deg);
}

.endpoint-body {
    padding: 0;
}

.method-section {
    border-bottom: 1px solid #eee;
}

.method-section:last-child {
    border-bottom: none;
}

.method-header {
    background: #f8f9fa;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #dee2e6;
}

.method-badge {
    font-weight: 600;
    font-size: 0.8rem;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    margin-right: 1rem;
}

.method-get { background: #e3f2fd; color: #1976d2; }
.method-post { background: #e8f5e8; color: #388e3c; }
.method-put { background: #fff3e0; color: #f57c00; }
.method-delete { background: #ffebee; color: #d32f2f; }

.method-content {
    padding: 1.5rem;
}

.form-section {
    margin-bottom: 2rem;
}

.form-section:last-child {
    margin-bottom: 0;
}

.section-title {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e9ecef;
}

.form-group {
    margin-bottom: 1rem;
}

.form-label {
    font-weight: 500;
    color: #495057;
    margin-bottom: 0.5rem;
}

.form-control, .form-select {
    border-radius: 8px;
    border: 2px solid #e9ecef;
    padding: 0.75rem;
    transition: all 0.3s ease;
}

.form-control:focus, .form-select:focus {
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 0.2rem rgba(52, 152, 219, 0.25);
}

.path-indicator {
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
    color: #6c757d;
    background: #f8f9fa;
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
    margin-bottom: 0.5rem;
    display: inline-block;
}

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.loading-spinner {
    width: 3rem;
    height: 3rem;
}

.alert {
    border-radius: 10px;
    border: none;
}

.btn {
    border-radius: 8px;
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.action-buttons {
    position: sticky;
    bottom: 2rem;
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 -5px 15px rgba(0,0,0,0.1);
    margin-top: 2rem;
}

.search-container {
    background: white;
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.search-input {
    border-radius: 25px;
    border: 2px solid #e9ecef;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

.search-input:focus {
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 0.2rem rgba(52, 152, 219, 0.25);
}

.hidden {
    display: none !important;
}

.changed {
    border-left: 4px solid var(--warning-color) !important;
    background-color: #fff9c4 !important;
}

.saved {
    border-left: 4px solid var(--success-color) !important;
    background-color: #d4edda !important;
}

@media (max-width: 768px) {
    .main-container {
        margin-top: 1rem;
    }
    
    .config-header {
        padding: 1.5rem;
    }
    
    .endpoint-header {
        padding: 1rem;
    }
    
    .method-content {
        padding: 1rem;
    }
}
