* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #0e1117 0%, #1a1f2e 100%);
    color: #e0e0e0;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
.header {
    text-align: center;
    padding: 40px 20px 20px;
    border-bottom: 2px solid #ff6b00;
    margin-bottom: 40px;
}

.header h1 {
    font-size: 2.5em;
    color: #ff6b00;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.1em;
    color: #a0a0a0;
}

/* Content */
.content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* Info Section */
.info-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.info-box {
    background: #262730;
    padding: 20px;
    border-radius: 8px;
    border-left: 4px solid #ff6b00;
}

.info-box h3 {
    color: #ff6b00;
    margin-bottom: 10px;
}

.info-box p {
    margin-bottom: 10px;
    line-height: 1.6;
}

.info-box code {
    background: #0e1117;
    padding: 8px 12px;
    border-radius: 4px;
    color: #ffb366;
    display: block;
    margin-top: 10px;
    font-family: 'Courier New', monospace;
}

.info-box ul {
    list-style-position: inside;
    margin-top: 10px;
}

.info-box li {
    margin: 5px 0;
    color: #d0d0d0;
}

/* Control Panel */
.control-panel {
    background: #262730;
    padding: 30px;
    border-radius: 8px;
    border: 1px solid #404050;
}

.control-panel h2 {
    color: #ff6b00;
    margin-bottom: 20px;
}

/* Form */
.form {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.form-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    color: #ffb366;
}

.form-group input[type="range"] {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #404050;
    outline: none;
    -webkit-appearance: none;
}

.form-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #ff6b00;
    cursor: pointer;
}

.form-group input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #ff6b00;
    cursor: pointer;
    border: none;
}

.form-group select {
    padding: 10px;
    border-radius: 4px;
    border: 1px solid #404050;
    background: #1a1f2e;
    color: #e0e0e0;
    font-size: 1em;
}

.slider-value {
    color: #ff6b00;
    font-weight: bold;
    font-size: 1.1em;
}

/* Buttons */
.btn-primary {
    background: linear-gradient(135deg, #ff6b00 0%, #ff8533 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 6px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    align-self: flex-start;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 0, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Loading */
.loading {
    display: none;
    text-align: center;
    padding: 20px;
}

.htmx-indicator.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #404050;
    border-top: 4px solid #ff6b00;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Results Section */
.results-section {
    margin-top: 30px;
}

.placeholder {
    text-align: center;
    color: #808080;
    font-size: 1.1em;
    padding: 40px;
    background: #262730;
    border-radius: 8px;
    border: 2px dashed #404050;
}

.results-box {
    background: #262730;
    padding: 25px;
    border-radius: 8px;
    border: 1px solid #404050;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.results-box h3 {
    color: #ff6b00;
    margin-bottom: 20px;
    font-size: 1.4em;
}

/* Table */
.results-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 25px;
}

.results-table thead {
    background: #1a1f2e;
}

.results-table th {
    padding: 12px;
    text-align: left;
    color: #ff6b00;
    font-weight: 600;
    border-bottom: 2px solid #ff6b00;
}

.results-table td {
    padding: 12px;
    border-bottom: 1px solid #404050;
}

.results-table tbody tr:hover {
    background: #1a1f2e;
}

.results-table strong {
    color: #ffb366;
}

/* Metrics */
.metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.metric-card {
    background: #1a1f2e;
    padding: 20px;
    border-radius: 6px;
    border-left: 4px solid #ff6b00;
    text-align: center;
}

.metric-label {
    color: #a0a0a0;
    font-size: 0.9em;
    margin-bottom: 8px;
}

.metric-value {
    color: #ff6b00;
    font-size: 1.8em;
    font-weight: bold;
}

/* Footer */
.footer {
    text-align: center;
    padding: 20px;
    color: #808080;
    margin-top: 40px;
    border-top: 1px solid #404050;
}

/* Responsive */
@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
    
    .info-section {
        grid-template-columns: 1fr;
    }
    
    .metrics {
        grid-template-columns: 1fr;
    }
    
    .header h1 {
        font-size: 1.8em;
    }
}