/* Compact Kinetics Controls Bar */
.kinetics-controls-compact {
    width: 100%;
    max-width: 1200px;
    margin: 1rem auto;
    background: rgba(255, 255, 255, 0.95); /* Light background for visibility */
    border-radius: 12px;
    padding: 1rem;
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.kinetics-compact-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.kinetics-compact-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 120px;
}

.kinetics-compact-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #374151; /* Dark text for light background */
    white-space: nowrap;
}

.kinetics-compact-select,
.kinetics-compact-input {
    width: 70px;
    padding: 0.25rem 0.5rem;
    border: 1px solid #d1d5db; /* Light border */
    border-radius: 6px;
    background: #ffffff; /* White background */
    color: #111827; /* Dark text */
    font-size: 0.85rem;
    text-align: center;
}

.kinetics-compact-select:focus,
.kinetics-compact-input:focus {
    outline: none;
    border-color: #7f5dff;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(127, 93, 255, 0.1);
}

.kinetics-compact-buttons {
    display: flex;
    gap: 0.5rem;
    margin-left: auto;
}

.kinetics-compact-btn {
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    border: none;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.kinetics-compact-info {
    margin-top: 0.5rem;
    text-align: center;
    font-size: 0.8rem;
    color: #6b7280; /* Dark gray text for light background */
}

.kinetics-compact-info .equation-display {
    font-family: 'Courier New', monospace;
    background: rgba(0, 0, 0, 0.05); /* Light gray background */
    padding: 0.25rem 0.5rem;
    border-radius: 3px;
    margin-right: 1rem;
    color: #374151; /* Dark text */
}

/* Responsive adjustments for compact controls */
@media (max-width: 768px) {
    .kinetics-compact-row {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .kinetics-compact-group {
        min-width: auto;
        width: 100%;
        justify-content: space-between;
    }
    
    .kinetics-compact-buttons {
        margin-left: 0;
        justify-content: center;
    }
}

/* Compact Titration Controls Bar */
.titration-controls-compact {
    width: 100%;
    max-width: 1200px;
    margin: 1rem auto;
    background: rgba(248, 250, 252, 0.98); /* Very light blue-gray background for better visibility */
    border-radius: 12px;
    padding: 1rem;
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.titration-compact-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 0.5rem;
}

.titration-compact-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 120px;
}

.titration-compact-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #374151; /* Dark text for light background */
    white-space: nowrap;
}

.titration-compact-select,
.titration-compact-input {
    width: 160px;
    padding: 0.25rem 0.5rem;
    border: 1px solid #d1d5db; /* Light border */
    border-radius: 6px;
    background: #ffffff; /* Pure white background for inputs */
    color: #111827; /* Dark text */
    font-size: 0.85rem;
    text-align: center;
}

.titration-compact-select:focus,
.titration-compact-input:focus {
    outline: none;
    border-color: #7f5dff;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(127, 93, 255, 0.1);
}

.titration-compact-inline {
    display: flex;
    gap: 0.25rem;
    align-items: center;
}

.titration-compact-buttons {
    display: flex;
    gap: 0.5rem;
    margin-left: auto;
}

.titration-compact-btn {
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    border: none;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.titration-compact-info {
    margin-top: 0.5rem;
    text-align: center;
    font-size: 0.8rem;
    color: #6b7280; /* Dark gray text for light background */
}

.titration-compact-info .equation-display {
    font-family: 'Courier New', monospace;
    background: rgba(0, 0, 0, 0.05); /* Light gray background */
    padding: 0.25rem 0.5rem;
    border-radius: 3px;
    margin-right: 1rem;
    color: #374151; /* Dark text */
}

/* Responsive adjustments for titration compact controls */
@media (max-width: 768px) {
    .titration-compact-row {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .titration-compact-group {
        min-width: auto;
        width: 100%;
        justify-content: space-between;
    }
    
    .titration-compact-buttons {
        margin-left: 0;
        justify-content: center;
    }
}

/* Legacy Kinetics Styles (kept for compatibility) */

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

.control-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.control-group label {
    font-weight: 500;
    color: #2c3e50;
    font-size: 0.9rem;
}

.kinetics-select,
.kinetics-input {
    padding: 8px 12px;
    border: 1px solid #bdc3c7;
    border-radius: 4px;
    font-size: 0.9rem;
    background: white;
    transition: border-color 0.2s;
}

.kinetics-select:focus,
.kinetics-input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

.kinetics-buttons {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.kinetics-info {
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
    border-left: 4px solid #3498db;
}

.equation-display {
    font-family: 'Courier New', monospace;
    font-size: 1rem;
    color: #2c3e50;
    margin-bottom: 5px;
}

.half-life-display {
    font-size: 0.9rem;
    color: #7f8c8d;
}

/* Custom titration inputs */
.custom-inputs-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    width: 100%;
    margin-top: 0.5rem;
    padding: 1rem;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.custom-input-group {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    min-width: 120px;
    flex: 1;
}

.custom-input-group label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #374151;
    white-space: nowrap;
}

.custom-input-group input,
.custom-input-group select {
    padding: 0.375rem 0.5rem;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 0.875rem;
    background: #ffffff;
}

.custom-input-group input:focus,
.custom-input-group select:focus {
    outline: none;
    border-color: #7f5dff;
    box-shadow: 0 0 0 2px rgba(127, 93, 255, 0.1);
}

/* Responsive design for custom inputs */
@media (max-width: 768px) {
    .custom-inputs-grid {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .custom-input-group {
        min-width: unset;
        width: 100%;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .kinetics-controls {
        grid-template-columns: 1fr;
    }
    
    .kinetics-buttons {
        flex-direction: column;
    }
    
    .custom-inputs-grid {
        grid-template-columns: 1fr;
    }
}