/* Load Test Script Generator - Modern Mobile-First Design */

/* Main Generator Container */
.load-test-generator {
    margin-bottom: 2rem;
}

.generator-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

/* Panel Styles */
.config-panel,
.output-panel {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: fit-content;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.panel-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
    color: white;
}

.panel-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.875rem;
    font-weight: 500;
}

.config-content {
    padding: 1.5rem;
}

.output-content {
    padding: 0;
    flex: 1;
    min-height: 500px;
    display: flex;
    flex-direction: column;
}

/* Configuration Groups */
.config-group {
    margin-bottom: 1.5rem;
}

.config-group:last-child {
    margin-bottom: 0;
}

.config-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9375rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
}

.label-icon {
    font-size: 1.125rem;
}

.config-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

/* Form Inputs */
.text-input,
.select-input,
.textarea-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 0.9375rem;
    transition: all 0.2s ease;
    background: #ffffff;
    color: #111827;
}

.text-input:focus,
.select-input:focus,
.textarea-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.textarea-input {
    resize: vertical;
    
    font-size: 0.875rem;
    line-height: 1.5;
}

.select-input {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23374151' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    padding-right: 2.5rem;
}

/* Checkbox Group */
.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: background-color 0.2s ease;
}

.checkbox-item:hover {
    background-color: #f9fafb;
}

.checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #667eea;
}

.checkbox-label {
    font-size: 0.9375rem;
    color: #374151;
    user-select: none;
}

/* Generate Button */
.generate-btn {
    width: 100%;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    margin-top: 1rem;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.generate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
}

.generate-btn:active {
    transform: translateY(0);
}

.btn-icon {
    font-size: 1.25rem;
}

/* Script Stats */
.script-stats {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.9);
}

.stat-item {
    display: flex;
    align-items: baseline;
    gap: 0.25rem;
}

.stat-value {
    font-weight: 600;
    font-size: 1rem;
}

.stat-label {
    font-size: 0.75rem;
    opacity: 0.8;
}

.stat-divider {
    opacity: 0.5;
}

/* Header Actions */
.header-actions {
    display: flex;
    gap: 0.5rem;
}

.action-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
}

.action-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.action-icon {
    font-size: 1.125rem;
}

/* Code Editor */
.code-editor {
    width: 100%;
    height: 100%;
    min-height: 500px;
    border: none;
    border-radius: 0;
}

/* Mobile Responsive */
@media (max-width: 1024px) {
    .generator-layout {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .config-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .load-test-generator {
        margin-top: 1.5rem;
    }

    .panel-header {
        padding: 1rem;
        flex-wrap: wrap;
        gap: 0.75rem;
    }

    .panel-title {
        font-size: 1.125rem;
    }

    .config-content {
        padding: 1.25rem;
    }

    .config-group {
        margin-bottom: 1.25rem;
    }

    .config-label {
        font-size: 0.875rem;
    }

    .text-input,
    .select-input,
    .textarea-input {
        padding: 0.625rem 0.875rem;
        font-size: 0.875rem;
    }

    .generate-btn {
        padding: 0.875rem 1.25rem;
        font-size: 0.9375rem;
    }

    .output-content {
        min-height: 400px;
    }

    .code-editor {
        min-height: 400px;
    }

    .header-left {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .script-stats {
        font-size: 0.8125rem;
    }
}

@media (max-width: 480px) {
    .config-content {
        padding: 1rem;
    }

    .panel-header {
        padding: 0.875rem;
    }

    .checkbox-group {
        gap: 0.5rem;
    }

    .checkbox-item {
        padding: 0.375rem;
    }

    .action-btn {
        width: 32px;
        height: 32px;
    }

    .action-icon {
        font-size: 1rem;
    }
}

/* Dark mode support (if needed) */
@media (prefers-color-scheme: dark) {
    .config-panel,
    .output-panel {
        background: #1f2937;
        color: #f9fafb;
    }

    .config-label {
        color: #e5e7eb;
    }

    .text-input,
    .select-input,
    .textarea-input {
        background: #374151;
        border-color: #4b5563;
        color: #f9fafb;
    }

    .text-input:focus,
    .select-input:focus,
    .textarea-input:focus {
        border-color: #667eea;
    }

    .checkbox-item:hover {
        background-color: #374151;
    }

    .checkbox-label {
        color: #e5e7eb;
    }
}
