/**
 * LiveChatAI WordPress Plugin - Admin Styles
 * Simple, clean and centered design
 * 
 * @package LiveChatAI
 * @version 1.0.0
 * @license GPL-2.0+
 */

/* CSS Variables - Minimal color palette */
:root {
    --livechatai-primary: #000000;
    --livechatai-primary-hover: #333333;
    --livechatai-success: #00a32a;
    --livechatai-warning: #f56e28;
    --livechatai-border: #ddd;
    --livechatai-text: #333;
    --livechatai-text-light: #666;
    --livechatai-bg: #f9f9f9;
}

/* Main container - Centered and clean */
.livechatai-admin-wrap {
    max-width: 600px;
    margin: 20px auto;
    padding: 0 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* Header - Simple white design */
.livechatai-header {
    background: white;
    padding: 40px 20px;
    text-align: center;
    margin-bottom: 30px;
    border: 1px solid var(--livechatai-border);
    border-radius: 8px;
}

.livechatai-header img {
    max-width: 120px;
    height: auto;
    margin-bottom: 20px;
}

.livechatai-header h1 {
    margin: 0 0 10px 0;
    font-size: 24px;
    font-weight: 600;
    color: var(--livechatai-text);
}

.livechatai-header p {
    margin: 0;
    font-size: 16px;
    color: var(--livechatai-text-light);
    line-height: 1.5;
}

/* Alert components - Simple */
.livechatai-alert {
    display: flex;
    align-items: flex-start;
    padding: 12px 16px;
    border-radius: 4px;
    margin-bottom: 20px;
    border: 1px solid;
    background: white;
}

.livechatai-alert .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    margin-right: 8px;
    margin-top: 2px;
    flex-shrink: 0;
}

.livechatai-alert-success {
    border-color: var(--livechatai-success);
    color: #155724;
}

.livechatai-alert-success .dashicons {
    color: var(--livechatai-success);
}

.livechatai-alert-warning {
    border-color: var(--livechatai-warning);
    color: #721c24;
}

.livechatai-alert-warning .dashicons {
    color: var(--livechatai-warning);
}

.livechatai-alert strong {
    display: block;
    margin-bottom: 4px;
    font-weight: 600;
}

.livechatai-alert p {
    margin: 0;
    font-size: 14px;
}

/* Card components - Clean white cards */
.livechatai-card {
    background: white;
    border: 1px solid var(--livechatai-border);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 20px;
}

.livechatai-card-header {
    padding: 20px 20px 0 20px;
    margin-bottom: 20px;
}

.livechatai-card-header h2 {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--livechatai-text);
}

.livechatai-card-header p {
    margin: 0;
    color: var(--livechatai-text-light);
    font-size: 14px;
}

.livechatai-card-body {
    padding: 0 20px 20px 20px;
}

/* Form components - Simple and clean */
.livechatai-form-group {
    margin-bottom: 20px;
}

.livechatai-form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    color: var(--livechatai-text);
    font-size: 14px;
}

.livechatai-form-group input[type="text"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--livechatai-border);
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.2s ease;
    background: #fff;
    box-sizing: border-box;
}

.livechatai-form-group input[type="text"]:focus {
    outline: none;
    border-color: var(--livechatai-primary);
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

.livechatai-form-help {
    margin-top: 6px;
    font-size: 13px;
    color: var(--livechatai-text-light);
    line-height: 1.4;
}

.livechatai-form-help code {
    background: var(--livechatai-bg);
    padding: 2px 4px;
    border-radius: 3px;
    font-size: 12px;
    color: var(--livechatai-text);
}

.livechatai-form-help a {
    color: var(--livechatai-primary);
    text-decoration: none;
}

.livechatai-form-help a:hover {
    text-decoration: underline;
}

/* Button components - Simple black buttons */
.livechatai-btn {
    display: inline-flex;
    align-items: center;
    padding: 10px 16px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    gap: 6px;
}

.livechatai-btn-primary {
    background: var(--livechatai-primary);
    color: white;
}

.livechatai-btn-primary:hover {
    background: var(--livechatai-primary-hover);
    color: white;
}

.livechatai-btn .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
}

/* Status components - Minimal */
.livechatai-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    background: var(--livechatai-bg);
}

.livechatai-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.livechatai-status-active {
    color: var(--livechatai-success);
}

.livechatai-status-active .livechatai-status-dot {
    background: var(--livechatai-success);
}

.livechatai-status-inactive {
    color: var(--livechatai-text-light);
}

.livechatai-status-inactive .livechatai-status-dot {
    background: var(--livechatai-text-light);
}

/* Steps component - Clean and simple with black numbers */
.livechatai-steps {
    counter-reset: step;
}

.livechatai-step {
    counter-increment: step;
    position: relative;
    padding-left: 40px;
    margin-bottom: 24px;
}

.livechatai-step::before {
    content: counter(step);
    position: absolute;
    left: 0;
    top: 0;
    width: 24px;
    height: 24px;
    background: var(--livechatai-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 12px;
}

.livechatai-step h3 {
    margin: 0 0 6px 0;
    font-size: 15px;
    font-weight: 600;
    color: var(--livechatai-text);
}

.livechatai-step p {
    margin: 0 0 8px 0;
    color: var(--livechatai-text-light);
    line-height: 1.4;
    font-size: 14px;
}

/* Code block - Simple */
.livechatai-code-block {
    background: #f8f8f8;
    border: 1px solid var(--livechatai-border);
    padding: 12px;
    border-radius: 4px;
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 12px;
    line-height: 1.4;
    overflow-x: auto;
    margin: 8px 0;
    color: var(--livechatai-text);
}

/* Footer - Minimal */
.livechatai-footer {
    text-align: center;
    padding: 20px;
    color: var(--livechatai-text-light);
    font-size: 13px;
    border-top: 1px solid var(--livechatai-border);
    margin-top: 30px;
}

.livechatai-footer a {
    color: var(--livechatai-primary);
    text-decoration: none;
}

.livechatai-footer a:hover {
    text-decoration: underline;
}

/* Responsive design */
@media (max-width: 768px) {
    .livechatai-admin-wrap {
        margin: 10px;
        max-width: none;
    }
    
    .livechatai-header {
        padding: 24px 16px;
    }
    
    .livechatai-card-header,
    .livechatai-card-body {
        padding: 16px;
    }
    
    .livechatai-step {
        padding-left: 32px;
    }
    
    .livechatai-step::before {
        width: 20px;
        height: 20px;
        font-size: 11px;
    }
}

/* WordPress admin compatibility */
.wp-admin .livechatai-admin-wrap {
    background: transparent;
}

/* Success/error messages from WordPress */
.livechatai-admin-wrap .notice {
    margin: 0 0 20px 0;
}

/* Validation styling */
.livechatai-form-group input.valid {
    border-color: var(--livechatai-success);
}

.livechatai-form-group input.invalid {
    border-color: var(--livechatai-warning);
}

.livechatai-validation-message {
    margin-top: 4px;
    font-size: 12px;
    font-weight: 500;
}

/* Fade in animation */
.livechatai-fade-in {
    animation: livechatai-fadeIn 0.3s ease-out;
}

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