/* Main Container for all tools */
.mft-tool-container {
    background-color: #ffffff;
    padding: 25px 40px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    max-width: 700px;
    width: 100%;
    box-sizing: border-box;
    margin: 40px auto; /* Center the container */
}

/* Header */
.mft-tool-container header {
    text-align: center;
    margin-bottom: 30px;
    border-bottom: 1px solid #e0e0e0;
    padding-bottom: 20px;
}
.mft-tool-container header h1 {
    color: #2c3e50;
    margin: 0;
    font-size: 28px;
}
.mft-tool-container header p {
    margin-top: 8px;
    color: #7f8c8d;
    font-size: 16px;
}

/* Form & Sections */
.mft-tool-container .calculator-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
}
.mft-tool-container .form-section {
    border: 1px solid #e0e0e0;
    padding: 20px;
    border-radius: 8px;
}
.mft-tool-container .form-section h2 {
    margin-top: 0;
    font-size: 20px;
    color: #34495e;
    margin-bottom: 20px;
}

/* Ingredient List from Food Cost Calculator*/
#ingredientList {
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.ingredient-row {
    display: grid;
    grid-template-columns: 3fr 2fr 2fr 1fr;
    gap: 10px;
    align-items: center;
}
.ingredient-row input {
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #bdc3c7;
    font-size: 14px;
    width: 100%;
}
 .ingredient-row input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}
.remove-ingredient-btn {
    background-color: #e74c3c;
    color: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    text-align: center;
    line-height: 30px;
    transition: background-color 0.3s;
}
.remove-ingredient-btn:hover {
    background-color: #c0392b;
}

/* Buttons */
.add-ingredient-btn {
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 10px 15px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.3s;
    margin-top: 15px;
    align-self: flex-start;
}
.add-ingredient-btn:hover {
    background-color: #2980b9;
}

/* Input Grids and Groups */
.final-calc-grid, .input-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: center;
}
.input-group {
    display: flex;
    flex-direction: column;
}
.input-group label {
    font-weight: 600;
    margin-bottom: 6px;
    font-size: 14px;
    color: #555;
}
.input-group input {
    padding: 12px;
    border-radius: 6px;
    border: 1px solid #bdc3c7;
    font-size: 16px;
    width: 100%;
}

/* Results Section */
#results, #breakevenResults {
    margin-top: 25px;
    padding: 25px;
    border-radius: 8px;
    background-color: #ecf0f1;
    text-align: center;
}
#results h2, #breakevenResults h2 {
    margin-top: 0;
    margin-bottom: 10px;
    color: #2c3e50;
    font-size: 20px;
}
#resultText, #breakevenResultText {
    font-size: 18px;
    line-height: 1.6;
}
#resultText span, #breakevenResultText span {
    font-size: 32px;
    font-weight: 700;
    color: #2c3e50;
}
#resultText .good { color: #2ecc71; }
#resultText .warn { color: #f39c12; }
#resultText .bad { color: #e74c3c; }

@media (max-width: 600px) {
    .ingredient-row {
        grid-template-columns: 1fr;
    }
    .final-calc-grid, .input-grid {
        grid-template-columns: 1fr;
    }
    .mft-tool-container {
        padding: 20px;
    }
}
