/* SEO Audit Widget - Frontend Styles */
.seo-audit-widget-container {
    max-width: 100%;
    margin: 20px 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.seo-audit-widget {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    padding: 25px;
    color: white;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.seo-audit-widget::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    z-index: 0;
}

.seo-audit-widget > * {
    position: relative;
    z-index: 1;
}

.seo-audit-header h3 {
    margin: 0 0 10px 0;
    font-size: 24px;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.seo-audit-header p {
    margin: 0 0 20px 0;
    opacity: 0.9;
    font-size: 14px;
}

.seo-audit-form {
    margin-bottom: 20px;
}

.input-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.domain-input {
    flex: 1;
    min-width: 200px;
    padding: 12px 16px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    background: rgba(255, 255, 255, 0.95);
    color: #333;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.domain-input:focus {
    outline: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    transform: translateY(-2px);
}

.check-button {
    padding: 12px 24px;
    background: linear-gradient(45deg, #ff6b6b, #ee5a24);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(238, 90, 36, 0.4);
    min-width: 120px;
}

.check-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(238, 90, 36, 0.6);
}

.check-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.loading-spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.seo-audit-result {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
    color: #333;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.loading-message {
    text-align: center;
    padding: 20px;
    font-size: 16px;
    color: #666;
}

.audit-results h4 {
    margin: 0 0 20px 0;
    color: #2c3e50;
    font-size: 20px;
    border-bottom: 2px solid #3498db;
    padding-bottom: 10px;
}

.result-section {
    margin-bottom: 25px;
    padding: 15px;
    border-radius: 6px;
    background: #f8f9fa;
}

.result-section h5 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #2c3e50;
}

.ssl-section {
    border-left: 4px solid #e74c3c;
}

.pagespeed-section {
    border-left: 4px solid #3498db;
}

.ssl-result p {
    margin: 8px 0;
    font-size: 14px;
}

.status-READY { color: #27ae60; font-weight: bold; }
.status-ERROR { color: #e74c3c; font-weight: bold; }
.grade-A { color: #27ae60; font-weight: bold; }
.grade-B { color: #f39c12; font-weight: bold; }
.grade-C { color: #e67e22; font-weight: bold; }
.grade-D { color: #e74c3c; font-weight: bold; }
.grade-F { color: #c0392b; font-weight: bold; }

.pagespeed-scores {
    margin-top: 15px;
}

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

.score-item {
    display: flex;
    flex-direction: column;
    padding: 12px;
    background: white;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    gap: 8px;
}

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

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

.score-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.8s ease-in-out;
    position: relative;
}

.score-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.score-label {
    font-weight: 600;
    color: #2c3e50;
}

.score-value {
    font-weight: bold;
    font-size: 18px;
    padding: 4px 8px;
    border-radius: 4px;
}

.score-good {
    background: #d5f4e6;
    color: #27ae60;
}

.score-average {
    background: #fef5e7;
    color: #f39c12;
}

.score-poor {
    background: #fadbd8;
    color: #e74c3c;
}

.core-web-vitals {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #dee2e6;
}

.core-web-vitals h6 {
    margin: 0 0 15px 0;
    color: #2c3e50;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.vitals-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 10px;
}

.vital-item {
    display: flex;
    flex-direction: column;
    padding: 10px;
    background: white;
    border-radius: 4px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.vital-label {
    font-size: 12px;
    color: #6c757d;
    margin-bottom: 4px;
}

.vital-value {
    font-weight: bold;
    color: #2c3e50;
    font-size: 14px;
}

.error-message {
    color: #e74c3c;
    background: #fadbd8;
    padding: 12px;
    border-radius: 4px;
    border-left: 4px solid #e74c3c;
    margin: 10px 0;
}

.seo-audit-info {
    margin-top: 15px;
    opacity: 0.8;
}

.seo-audit-info small {
    font-size: 12px;
}

/* Website-Vorschau */
.seo-audit-preview {
    margin-top: 20px;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.preview-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 15px 20px;
    margin: 0;
}

.preview-header h4 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.preview-container {
    position: relative;
    width: 100%;
    height: 400px;
    overflow: hidden;
}

.preview-container iframe {
    width: 100%;
    height: 100%;
    border: none;
    transform: scale(0.5);
    transform-origin: top left;
    width: 200%;
    height: 200%;
}

/* Desktop Monitor Preview */
.monitor {
    width: 100%;
    background: #2b2b2b;
    border-radius: 10px 10px 0 0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    padding: 10px;
    margin-top: 15px;
}
.monitor-screen {
    background: #000;
    border-radius: 6px;
    overflow: hidden;
    height: 420px;
}
.monitor-screen iframe {
    width: 100%;
    height: 100%;
    border: 0;
}
.monitor-stand {
    width: 120px;
    height: 10px;
    background: #444;
    margin: 12px auto 0;
    border-radius: 0 0 6px 6px;
}

/* Site/Keywords sections */
.site-section { border-left: 4px solid #6f42c1; }
.keywords-section { border-left: 4px solid #20c997; }
.heatmap-section { border-left: 4px solid #ff6b6b; }
.site-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.suggestions ul { margin: 8px 0 0; padding-left: 18px; }
.keyword-summary { margin: 10px 0; font-weight: 600; }

/* Loading Bar Styles */
.loading-container {
    text-align: center;
    padding: 20px;
}

.loading-progress {
    margin-top: 20px;
}

.loading-bar {
    width: 100%;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 15px;
}

.loading-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 4px;
    animation: loadingProgress 3s ease-in-out;
    width: 0%;
}

@keyframes loadingProgress {
    0% { width: 0%; }
    25% { width: 25%; }
    50% { width: 50%; }
    75% { width: 75%; }
    100% { width: 100%; }
}

.loading-steps {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}

.loading-steps .step {
    padding: 8px 12px;
    background: #f8f9fa;
    border-radius: 20px;
    font-size: 12px;
    color: #6c757d;
    transition: all 0.3s ease;
}

.loading-steps .step.active {
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    transform: scale(1.05);
}

/* Enhanced Site Analysis Styles */
.site-item {
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border-left: 4px solid #6f42c1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.site-badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.site-badge.good {
    background: #d4edda;
    color: #155724;
}

.site-badge.warning {
    background: #fff3cd;
    color: #856404;
}

.site-badge.info {
    background: #d1ecf1;
    color: #0c5460;
}

.h-tag {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    margin: 2px;
    display: inline-block;
}

.h-tag.h1 { background: #ff6b6b; color: white; }
.h-tag.h2 { background: #4ecdc4; color: white; }
.h-tag.h3 { background: #45b7d1; color: white; }
.h-tag.h4 { background: #96ceb4; color: white; }
.h-tag.h5 { background: #feca57; color: white; }
.h-tag.h6 { background: #ff9ff3; color: white; }

.headings {
    flex-direction: column;
    align-items: flex-start;
}

.headings .h-tag {
    margin: 4px 4px 4px 0;
}

/* Heatmap Styles */
.heatmap-overlay {
    margin-top: 20px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 2px solid #e9ecef;
}

.heatmap-controls {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.heatmap-btn {
    padding: 8px 16px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.heatmap-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.heatmap-visualization {
    position: relative;
    background: white;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    min-height: 400px;
    overflow: hidden;
}

.heatmap-canvas {
    position: relative;
    width: 100%;
    height: 400px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.heatmap-spot {
    position: absolute;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.heatmap-spot:hover {
    transform: scale(1.2);
    z-index: 20;
}

.spot-priority {
    color: white;
    font-weight: bold;
    font-size: 12px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

.conversion-element {
    position: absolute;
    width: 40px;
    height: 40px;
    background: #28a745;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    font-size: 20px;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
    transition: all 0.3s ease;
}

.conversion-element:hover {
    transform: scale(1.1);
    background: #20c997;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
    100% { transform: scale(1); opacity: 1; }
}

.heatmap-summary {
    background: white;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 15px;
    border-left: 4px solid #ff6b6b;
}

.heatmap-summary h6 {
    margin: 5px 0;
    color: #2c3e50;
}

.hotspots-list {
    display: grid;
    gap: 10px;
    margin-top: 15px;
}

.hotspot-item {
    background: white;
    padding: 12px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.hotspot-item small {
    color: #6c757d;
    font-size: 12px;
}

.heatmap-suggestions {
    background: #e3f2fd;
    padding: 15px;
    border-radius: 6px;
    margin-top: 15px;
    border-left: 4px solid #2196f3;
}

.heatmap-suggestions h6 {
    margin: 0 0 10px 0;
    color: #1976d2;
}

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

.heatmap-suggestions li {
    margin: 5px 0;
    color: #424242;
}

/* Enhanced Error Handling */
.error-container {
    background: #fff5f5;
    border: 2px solid #fed7d7;
    border-radius: 8px;
    padding: 20px;
    margin: 15px 0;
}

.error-suggestions {
    margin-top: 15px;
    padding: 15px;
    background: #f7fafc;
    border-radius: 6px;
    border-left: 4px solid #3182ce;
}

.error-suggestions h6 {
    margin: 0 0 10px 0;
    color: #2d3748;
    font-size: 14px;
}

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

.error-suggestions li {
    margin: 5px 0;
    color: #4a5568;
    font-size: 13px;
}

/* Kontakt-Sektion */
.contact-section {
    border-left: 4px solid #28a745;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.contact-actions {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-top: 15px;
}

.contact-btn, .preview-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.contact-btn {
    background: linear-gradient(45deg, #28a745, #20c997);
    color: white;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.contact-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.4);
}

.preview-btn {
    background: linear-gradient(45deg, #17a2b8, #6f42c1);
    color: white;
    box-shadow: 0 4px 15px rgba(23, 162, 184, 0.3);
}

.preview-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(23, 162, 184, 0.4);
}

/* Responsive Design für neue Features */
@media (max-width: 768px) {
    .contact-actions {
        flex-direction: column;
    }
    
    .contact-btn, .preview-btn {
        width: 100%;
        justify-content: center;
    }
    
    .preview-container {
        height: 300px;
    }
    
    .preview-container iframe {
        transform: scale(0.3);
        width: 333%;
        height: 333%;
    }
}

@media (max-width: 480px) {
    .preview-container {
        height: 250px;
    }
    
    .preview-container iframe {
        transform: scale(0.25);
        width: 400%;
        height: 400%;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .seo-audit-widget {
        padding: 20px;
    }
    
    .input-group {
        flex-direction: column;
    }
    
    .domain-input {
        min-width: 100%;
    }
    
    .check-button {
        width: 100%;
    }
    
    .score-grid {
        grid-template-columns: 1fr;
    }
    
    .vitals-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .seo-audit-widget {
        padding: 15px;
    }
    
    .seo-audit-header h3 {
        font-size: 20px;
    }
    
    .result-section {
        padding: 10px;
    }
}
