/* Advanced Tools Styles */
.tools-hero {
    text-align: center;
    padding: 4rem 0 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    margin: -2rem -2rem 3rem;
    border-radius: 0 0 20px 20px;
}

.tools-hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.tools-hero p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.tool-section {
    background: white;
    border-radius: 15px;
    padding: 2.5rem;
    margin-bottom: 3rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
}

.tool-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.tool-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.tool-header h2 {
    color: var(--dark);
    margin-bottom: 0.5rem;
    font-size: 2rem;
}

.tool-header p {
    color: #666;
    font-size: 1.1rem;
}

/* AI Analysis Styles */
.upload-area {
    border: 3px dashed #ddd;
    border-radius: 12px;
    padding: 3rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    background: #fafafa;
}

.upload-area:hover, .upload-area.dragover {
    border-color: var(--primary);
    background: #f0f7ff;
}

.upload-placeholder .upload-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.7;
}

.upload-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    margin-top: 1rem;
    transition: all 0.3s ease;
}

.upload-btn:hover {
    background: #2980b9;
    transform: translateY(-2px);
}

.analysis-results {
    margin-top: 2rem;
    animation: fadeIn 0.5s ease;
}

.extracted-colors {
    display: flex;
    gap: 1rem;
    margin: 1.5rem 0;
    flex-wrap: wrap;
}

.extracted-color {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    position: relative;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.extracted-color:hover {
    transform: scale(1.1);
}

.extracted-color span {
    position: absolute;
    bottom: -25px;
    left: 0;
    right: 0;
    text-align: center;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Accessibility Checker Styles */
.color-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.color-input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.color-input-group label {
    font-weight: 600;
    color: var(--dark);
}

.color-input-group input[type="color"] {
    width: 60px;
    height: 60px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

.color-input-group input[type="text"] {
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: monospace;
}

.contrast-preview {
    margin: 2rem 0;
    padding: 2rem;
    border-radius: 8px;
    text-align: center;
}

.contrast-example {
    font-size: 1.5rem;
    font-weight: 600;
    padding: 1rem;
    border-radius: 8px;
}

.wcag-results {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 2rem;
}

.wcag-level, .contrast-ratio {
    text-align: center;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.wcag-level h4, .contrast-ratio h4 {
    margin-bottom: 0.5rem;
    color: var(--dark);
}

.status.pass {
    color: #27ae60;
    font-weight: 600;
}

.status.fail {
    color: #e74c3c;
    font-weight: 600;
}

/* Color Blindness Simulator */
.vision-types {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.vision-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    padding: 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.vision-option.active {
    background: var(--light);
    border: 2px solid var(--primary);
}

.vision-preview {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    margin-bottom: 0.5rem;
    border: 3px solid transparent;
}

.vision-option.active .vision-preview {
    border-color: var(--primary);
}

.vision-preview.normal { background: conic-gradient(red, yellow, lime, aqua, blue, magenta, red); }
.vision-preview.protanopia { background: linear-gradient(45deg, #555, #777, #999); }
.vision-preview.deuteranopia { background: linear-gradient(45deg, #666, #888, #aaa); }
.vision-preview.tritanopia { background: linear-gradient(45deg, #ff6b6b, #4ecdc4); }
.vision-preview.achromatopsia { background: linear-gradient(45deg, #888, #aaa, #ccc); }

.simulation-area {
    margin: 2rem 0;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 12px;
}

.color-test {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.test-element {
    padding: 1.5rem;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
    transition: all 0.3s ease;
}

.custom-colors {
    margin-top: 2rem;
    text-align: center;
}

.custom-color-inputs {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 1rem 0;
    flex-wrap: wrap;
}

.custom-color-inputs input[type="color"] {
    width: 50px;
    height: 50px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

/* Trend Analysis */
.industry-selector {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.industry-selector label {
    font-weight: 600;
    color: var(--dark);
}

.industry-selector select {
    padding: 0.5rem 1rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: white;
}

.trend-palettes {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.trend-palette {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.palette-colors {
    display: flex;
    height: 100px;
}

.palette-color {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.8rem;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.trend-insights {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--primary);
}

/* Buttons */
.btn-primary {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: #2980b9;
    transform: translateY(-2px);
}

.btn-secondary {
    background: #95a5a6;
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: #7f8c8d;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .tools-hero h1 {
        font-size: 2rem;
    }
    
    .tool-section {
        padding: 1.5rem;
    }
    
    .color-inputs {
        grid-template-columns: 1fr;
    }
    
    .wcag-results {
        grid-template-columns: 1fr;
    }
    
    .vision-types {
        gap: 0.5rem;
    }
    
    .color-test {
        grid-template-columns: 1fr;
    }
    
    .industry-selector {
        flex-direction: column;
        align-items: stretch;
    }
    
    .trend-palettes {
        grid-template-columns: 1fr;
    }
}