/* AI Content Humanizer WordPress Plugin Styles */

.ai-humanizer-container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
    border: 1px solid #e1e5e9;
}

.humanizer-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f2f5;
}

.humanizer-header h2 {
    color: #1a73e8;
    margin: 0 0 10px 0;
    font-size: 2.2em;
    font-weight: 600;
}

.humanizer-header p {
    color: #5f6368;
    margin: 0;
    font-size: 1.1em;
}

.humanizer-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 20px;
}

.input-section, .output-section {
    display: flex;
    flex-direction: column;
}

.input-controls, .output-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.input-controls label, .output-controls label {
    font-weight: 600;
    color: #202124;
    font-size: 1.1em;
}

.mode-selector {
    display: flex;
    align-items: center;
    gap: 10px;
}

.mode-selector label {
    font-size: 0.9em;
    font-weight: 500;
}

.mode-selector select {
    padding: 8px 12px;
    border: 2px solid #dadce0;
    border-radius: 6px;
    background: white;
    font-size: 0.9em;
    color: #3c4043;
}

.mode-selector select:focus {
    outline: none;
    border-color: #1a73e8;
    box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.1);
}

textarea {
    width: 100%;
    min-height: 300px;
    padding: 15px;
    border: 2px solid #dadce0;
    border-radius: 8px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    resize: vertical;
    transition: border-color 0.2s ease;
}

textarea:focus {
    outline: none;
    border-color: #1a73e8;
    box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.1);
}

textarea#output-text {
    background-color: #f8f9fa;
    color: #3c4043;
}

.input-stats, .output-stats {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    padding: 5px 0;
    font-size: 0.85em;
    color: #5f6368;
}

.button-group {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary {
    background: #1a73e8;
    color: white;
}

.btn-primary:hover {
    background: #1557b0;
    transform: translateY(-1px);
}

.btn-secondary {
    background: #f1f3f4;
    color: #3c4043;
}

.btn-secondary:hover {
    background: #e8eaed;
    transform: translateY(-1px);
}

.btn-copy {
    background: #34a853;
    color: white;
    padding: 8px 16px;
    font-size: 12px;
}

.btn-copy:hover {
    background: #2d8e47;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.analysis-panel {
    background: #f8f9fa;
    border: 1px solid #dadce0;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
}

.analysis-panel h3 {
    margin: 0 0 20px 0;
    color: #1a73e8;
    font-size: 1.3em;
}

.analysis-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.metric {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.metric label {
    font-weight: 500;
    color: #3c4043;
    font-size: 0.9em;
}

.score-bar {
    display: flex;
    align-items: center;
    gap: 10px;
}

.score-bar {
    background: #e8eaed;
    height: 8px;
    border-radius: 4px;
    position: relative;
    flex: 1;
}

.score-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s ease;
}

.score-fill.low {
    background: #34a853;
}

.score-fill.medium {
    background: #fbbc04;
}

.score-fill.high {
    background: #ea4335;
}

#ai-score-text {
    font-weight: 600;
    color: #3c4043;
    min-width: 40px;
}

.suggestions h4 {
    margin: 0 0 10px 0;
    color: #3c4043;
    font-size: 1.1em;
}

.suggestions ul {
    margin: 0;
    padding-left: 20px;
}

.suggestions li {
    margin-bottom: 5px;
    color: #5f6368;
    line-height: 1.4;
}

.loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    z-index: 100;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #1a73e8;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-overlay p {
    color: #5f6368;
    margin: 0;
    font-weight: 500;
}

/* Responsive Design */
@media (max-width: 768px) {
    .ai-humanizer-container {
        margin: 10px;
        padding: 15px;
    }
    
    .humanizer-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .humanizer-header h2 {
        font-size: 1.8em;
    }
    
    .input-controls, .output-controls {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .analysis-metrics {
        grid-template-columns: 1fr;
    }
}

/* Success and Error States */
.success-message {
    background: #e6f7e6;
    color: #2d5d2d;
    padding: 10px 15px;
    border-radius: 6px;
    margin: 10px 0;
    border-left: 4px solid #34a853;
}

.error-message {
    background: #fce8e6;
    color: #d93025;
    padding: 10px 15px;
    border-radius: 6px;
    margin: 10px 0;
    border-left: 4px solid #ea4335;
}

/* Focus and accessibility improvements */
.btn:focus,
textarea:focus,
select:focus {
    outline: 2px solid #1a73e8;
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .btn,
    .loading-overlay {
        display: none;
    }
    
    .ai-humanizer-container {
        box-shadow: none;
        border: 1px solid #ccc;
    }
}