/*
============================================================================
Copyright (c) 2024 HJJB, LLC
All Rights Reserved

This software is the proprietary information of HJJB, LLC.
Unauthorized use, reproduction, or distribution is strictly prohibited.

For licensing inquiries, please contact:
Email: licensing@thecoatlessprofessor.com
============================================================================
*/

:root {
    --primary-color: #3498db;
    --primary-hover: #2980b9;
    --secondary-color: #95a5a6;
    --secondary-hover: #7f8c8d;
    --success-color: #27ae60;
    --warning-color: #f39c12;
    --error-color: #e74c3c;
    --background: #ecf0f1;
    --container-bg: #ffffff;
    --text-color: #2c3e50;
    --border-color: #bdc3c7;
}

* {
    box-sizing: border-box;
}

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    background: var(--background);
    color: var(--text-color);
    line-height: 1.6;
}

.container {
    background: var(--container-bg);
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--border-color);
}

header h1 {
    margin: 0 0 10px 0;
    color: var(--primary-color);
}

header p {
    margin: 0;
    color: var(--secondary-color);
}

.section {
    margin-bottom: 25px;
}

.section h2 {
    margin-top: 0;
    margin-bottom: 15px;
    color: var(--text-color);
    font-size: 1.3em;
}

.section p {
    color: var(--secondary-color);
    margin-bottom: 10px;
}

textarea {
    width: 100%;
    min-height: 120px;
    padding: 15px;
    border: 2px solid var(--border-color);
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    resize: vertical;
    margin-bottom: 10px;
}

textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

.primary-button, .secondary-button {
    padding: 12px 30px;
    font-size: 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-right: 10px;
    margin-bottom: 10px;
}

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

.primary-button:hover {
    background-color: var(--primary-hover);
}

.secondary-button {
    background-color: var(--secondary-color);
    color: white;
}

.secondary-button:hover {
    background-color: var(--secondary-hover);
}

.optimal-result-card {
    padding: 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 8px;
    text-align: center;
}

.optimal-result-card h3 {
    margin: 0 0 20px 0;
    font-size: 1.2em;
}

.lambda-display {
    font-size: 3em;
    font-weight: bold;
    margin: 15px 0;
}

.lambda-interpretation {
    font-size: 1em;
    opacity: 0.9;
    margin-top: 10px;
}

.slider-container {
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.slider-container label {
    display: block;
    margin-bottom: 15px;
    font-weight: 600;
    font-size: 1.1em;
}

.slider-container input[type="range"] {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: #d3d3d3;
    outline: none;
    margin-bottom: 20px;
}

.slider-container input[type="range"]::-webkit-slider-thumb {
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
}

.slider-container input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
}

.common-lambdas {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 15px;
}

.lambda-btn {
    padding: 8px 16px;
    background-color: white;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9em;
    transition: all 0.3s;
}

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

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.stat-card {
    padding: 20px;
    border-radius: 8px;
    text-align: center;
}

.stat-card.before {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

.stat-card.after {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
}

.stat-card .stat-label {
    font-size: 0.85em;
    opacity: 0.9;
    margin-bottom: 8px;
}

.stat-card .stat-value {
    font-size: 1.5em;
    font-weight: bold;
}

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

.chart-container {
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.chart-container canvas {
    max-width: 100%;
    height: auto;
}

.chart-label {
    text-align: center;
    font-weight: 600;
    color: var(--text-color);
    margin-top: 10px;
    margin-bottom: 0;
}

.help-section {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 2px solid var(--border-color);
}

details {
    margin-bottom: 15px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 10px;
}

summary {
    cursor: pointer;
    font-weight: bold;
    padding: 5px;
    user-select: none;
}

summary:hover {
    color: var(--primary-color);
}

details ul,
details ol {
    margin: 10px 0;
    padding-left: 20px;
}

details li {
    margin-bottom: 5px;
}

details p {
    margin: 10px 0;
}
