/* Prompt Editor Dark Theme */
.prompt-editor-dark {
    color: #e0e0e0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    padding: 20px;
}

.prompt-editor-dark .container {
    max-width: 1200px;
    margin: 0 auto;
}

.prompt-editor-dark .header {
    text-align: center;
    margin-bottom: 40px;
}

.prompt-editor-dark .header h1 {
    color: #ffffff;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.prompt-editor-dark .header p {
    color: #b0b0b0;
    font-size: 1.1rem;
}

.prompt-editor-dark .controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}

.prompt-editor-dark .prompts-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 30px;
}

.prompt-editor-dark .prompt-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 25px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    width: 100%;
    display: flex;
    flex-direction: column;
    box-sizing: border-box; /* Ensure padding doesn't affect width */
}

.prompt-editor-dark .prompt-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    border-color: rgba(102, 126, 234, 0.3);
}

.prompt-editor-dark .prompt-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.prompt-editor-dark .prompt-card-content {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 20px;
    align-items: start;
}

.prompt-editor-dark .prompt-info {
    display: flex;
    flex-direction: column;
}

.prompt-editor-dark .prompt-preview-full {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 15px;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    color: #d0d0d0;
    max-height: 200px;
    overflow-y: auto;
    white-space: pre-wrap;
}

.prompt-editor-dark .prompt-card h3 {
    color: #ffffff;
    font-size: 1.3rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.prompt-editor-dark .prompt-card p {
    color: #b0b0b0;
    font-size: 0.9rem;
    margin-bottom: 15px;
    line-height: 1.5;
}

.prompt-editor-dark .btn-edit {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.prompt-editor-dark .btn-edit:hover {
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(240, 147, 251, 0.3);
}

/* Modal styles */
.prompt-editor-dark .modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
}

.prompt-editor-dark .modal-content {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    margin: 2% auto;
    padding: 35px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    width: 95%;
    max-width: 1000px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
}

.prompt-editor-dark .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.prompt-editor-dark .modal-header h2 {
    color: #ffffff;
    font-size: 1.5rem;
    margin: 0;
}

.prompt-editor-dark .close {
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.prompt-editor-dark .close:hover {
    color: #fff;
}

.prompt-editor-dark .form-group {
    margin-bottom: 20px;
}

.prompt-editor-dark .form-group label {
    display: block;
    color: #e0e0e0;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.prompt-editor-dark .form-group input,
.prompt-editor-dark .form-group textarea {
    width: 100%;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #e0e0e0;
    font-size: 14px;
    transition: all 0.3s ease;
    box-sizing: border-box; /* Ensure padding doesn't affect width */
}

.prompt-editor-dark .form-group input:focus,
.prompt-editor-dark .form-group textarea:focus {
    outline: none;
    border-color: rgba(102, 126, 234, 0.5);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.prompt-editor-dark .form-group textarea {
    min-height: 120px;
    resize: vertical;
    font-family: 'Courier New', monospace;
}

.prompt-editor-dark .variables-help {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.prompt-editor-dark .variables-help h4 {
    color: #ffffff;
    margin-bottom: 10px;
    font-size: 1rem;
}

.prompt-editor-dark .variables-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 8px;
}

.prompt-editor-dark .variable-item {
    background: rgba(102, 126, 234, 0.1);
    padding: 6px 10px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
    color: #a0a0ff;
}

.prompt-editor-dark .variable-list-textarea {
    min-height: 80px !important;
    font-family: 'Inter', sans-serif !important;
    font-size: 13px !important;
    line-height: 1.4 !important;
}

.prompt-editor-dark .status-message {
    padding: 12px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-weight: 500;
    display: none;
}

.prompt-editor-dark .status-success {
    background: rgba(86, 171, 47, 0.2);
    border: 1px solid rgba(86, 171, 47, 0.3);
    color: #a8e6cf;
}

.prompt-editor-dark .status-error {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid rgba(231, 76, 60, 0.3);
    color: #ff6b6b;
}

/* Responsive design */
@media (max-width: 768px) {
    .prompt-editor-dark .prompt-card-content {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .prompt-editor-dark .controls {
        flex-direction: column;
        align-items: stretch;
    }

    .prompt-editor-dark .modal-content {
        width: 98%;
        margin: 1% auto;
        padding: 20px;
    }

    .prompt-editor-dark .prompt-card {
        padding: 20px;
    }

    .prompt-editor-dark .prompt-card-header {
        flex-direction: column;
        gap: 15px;
    }
}
