/* Core Styling — Dark Industrial Lab */
body {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    margin: 0;
    padding: 40px;
    background: #0f1115;
    min-height: 100vh;
}

/* Dashboard Container */
.dashboard-wrapper {
    max-width: 1000px;
    margin: 0 auto;
    width: 100%;
}

.dashboard {
    background: #1e222b;
    border: 1px solid #2e3440;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    padding: 30px;
    display: flex;
    flex-direction: row;
    width: 100%;
    box-sizing: border-box;
    gap: 30px;
}

/* Column Layout via Flexbox */
.control-panel {
    flex: 35;
    min-width: 0;
    border-right: 1px solid #2e3440;
    padding-right: 10px;
}

.visualization-panel {
    flex: 65;
    min-width: 0;
}

/* Advanced Hardware Typography Header */
.main-header {
    font-family: 'Orbitron', sans-serif;
    color: #f8fafc;
    line-height: 0.9;
    margin-top: 0;
    margin-bottom: 12px;
    text-shadow: 0 0 15px rgba(249, 115, 22, 0.15);
}
.header-light {
    font-size: 22px;
    font-weight: 400;
    text-transform: lowercase;
    letter-spacing: 5px;
    color: #94a3b8;
}
.header-bold {
    font-size: 38px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #f8fafc;
    background: linear-gradient(to bottom, #f8fafc 60%, #cbd5e1 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    color: #94a3b8;
    font-size: 13px;
    margin-top: 0;
    margin-bottom: 25px;
}

/* Inputs & Buttons */
.file-input-wrapper {
    margin-bottom: 20px;
}
input[type="file"] {
    width: 100%;
    padding: 10px;
    background: #15181f;
    border: 1px solid #3b4252;
    border-radius: 6px;
    color: #cbd5e1;
    box-sizing: border-box;
}
button {
    background: #f97316; /* Metal Orange Accent */
    color: #0f1115;
    border: none;
    padding: 14px 20px;
    cursor: pointer;
    border-radius: 6px;
    font-size: 15px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    width: 100%;
    transition: background 0.2s;
}
button:hover {
    background: #ea580c;
}
button:disabled {
    background: #3b4252;
    color: #64748b;
    cursor: not-allowed;
}

/* Spinner & Text Layout */
.spinner-container {
    display: none;
    align-items: flex-start;
    gap: 12px;
    margin-top: 20px;
    color: #94a3b8;
    font-size: 14px;
}
.spinner {
    border: 3px solid rgba(249, 115, 22, 0.1);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border-left-color: #f97316;
    animation: spin 1s linear infinite;
    flex-shrink: 0;
    margin-top: 2px;
}
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
.spinner-text-wrapper {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.loading-status {
    color: #94a3b8;
}

.long-wait-notice {
    display: none;
    font-size: 12px;
    color: #eab308;
    line-height: 1.4;
    animation: pulse 2s infinite ease-in-out;
}
@keyframes pulse {
    0% { opacity: 0.6; }
    50% { opacity: 1; }
    100% { opacity: 0.6; }
}

/* --- NEW: BATCH PROGRESS ELEMENTS --- */
.batch-progress-container {
    display: none;
    margin-top: 25px;
    background: #15181f;
    border: 1px solid #2e3440;
    border-radius: 6px;
    padding: 12px;
}
.batch-progress-label {
    font-size: 11px;
    text-transform: uppercase;
    color: #94a3b8;
    letter-spacing: 1px;
    margin-bottom: 6px;
    font-weight: bold;
}
.progress-bar-bg {
    background: #0f1115;
    height: 8px;
    border-radius: 4px;
    width: 100%;
    overflow: hidden;
    border: 1px solid #2e3440;
}
.progress-bar-fill {
    height: 100%;
    width: 0%;
    background: #f97316;
    border-radius: 4px;
    transition: width 0.3s ease;
}
.batch-progress-text {
    font-size: 12px;
    color: #cbd5e1;
    margin-top: 6px;
    font-family: monospace;
}

/* --- DIGITAL SCORE DISPLAY --- */
.score-display {
    background: #15181f;
    border: 1px solid #3b4252;
    border-radius: 8px;
    padding: 18px 15px;
    text-align: center;
    margin-bottom: 30px;
    box-shadow: inset 0 2px 8px rgba(0,0,0,0.4);
}
.score-label {
    font-size: 12px;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 5px;
}
.score-number {
    font-size: 52px;
    font-weight: 900;
    color: #f97316; 
    font-family: monospace;
    letter-spacing: 2px;
    text-shadow: 0 0 12px rgba(249, 115, 22, 0.2);
    transition: color 0.8s ease;
}

.score-classification {
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 6px;
    min-height: 18px; 
    transition: color 0.8s ease;
}

/* --- THERMOMETER VISUALISIERUNG --- */
.thermometer-container {
    position: relative;
    height: 320px;
    margin: 20px auto 30px auto;
    width: 100%;
    max-width: 380px;
}

.thermometer-tube {
    position: absolute;
    left: 80px;
    top: 0;
    width: 28px;
    height: 100%;
    background: linear-gradient(to top, 
        #16a34a 0%,    
        #84cc16 25%,   
        #eab308 50%,   
        #f97316 75%,   
        #dc2626 100%   
    );
    border-radius: 14px;
    box-shadow: inset 0 3px 10px rgba(0,0,0,0.8), 0 1px 0 rgba(255,255,255,0.05);
}

.ticks-axis {
    position: absolute;
    left: 30px;
    top: 0;
    width: 40px;
    height: 100%;
}
.tick-mark {
    position: absolute;
    width: 12px;
    height: 2px;
    background: #475569;
    right: 0;
}
.tick-label {
    position: absolute;
    right: 18px;
    top: -8px;
    font-size: 13px;
    font-weight: bold;
    color: #94a3b8;
    font-family: monospace;
}

.labels-right {
    position: absolute;
    left: 125px;
    height: 100%;
    top: 0;
    right: 10px;
}
.label-top { 
    position: absolute; 
    top: -2px; 
    font-size: 11px; 
    font-weight: bold; 
    color: #ef4444; 
    letter-spacing: 0.8px; 
}
.label-bottom { 
    position: absolute; 
    bottom: -2px; 
    font-size: 11px; 
    font-weight: bold; 
    color: #10b981; 
    letter-spacing: 0.8px; 
}

.thermometer-marker {
    position: absolute;
    left: -12px;
    width: 52px;
    bottom: 0%; 
    transition: bottom 1.2s cubic-bezier(0.19, 1, 0.22, 1);
    display: none;
}
.marker-line {
    position: absolute;
    width: 52px;
    height: 6px;
    background: #f8fafc;
    border: 1px solid #0f1115;
    border-radius: 3px;
    top: -3px;
    box-shadow: 0 0 10px rgba(255,255,255,0.7);
}

.result-card {
    background: #15181f;
    border: 1px solid #2e3440;
    border-radius: 6px;
    padding: 15px;
    margin-top: 25px;
    font-size: 14px;
    color: #cbd5e1;
    line-height: 1.6;
}
.success-banner {
    color: #10b981;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.global-footer {
    padding: 25px 20px;
    margin-top: 20px;
    font-size: 11.5px;
    color: #8e9bb0;
    text-align: center;
    line-height: 1.6;
    border-top: 1px solid rgba(255,255,255,0.05);
    max-width: 850px;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 768px) {
    body { padding: 15px; }
    .dashboard { flex-direction: column; padding: 20px; gap: 25px; }
    .control-panel { border-right: none; border-bottom: 1px solid #2e3440; padding-right: 0; padding-bottom: 25px; }
    .visualization-panel { padding-left: 0; }
    .main-header { text-align: center; }
    .subtitle { text-align: center; }
    .score-number { font-size: 42px; }
}
