:root {
    --bmit-primary: #2563eb;
    --bmit-primary-hover: #1d4ed8;
    --bmit-bg: #f8fafc;
    --bmit-card-bg: #ffffff;
    --bmit-text-dark: #1e293b;
    --bmit-text-light: #64748b;
    --bmit-border: #e2e8f0;
    
    /* Health Condition Status Colors */
    --bmit-underweight: #3b82f6; /* Blue */
    --bmit-normal: #10b981;      /* Green */
    --bmit-overweight: #f59e0b;  /* Orange */
    --bmit-obese: #ef4444;       /* Red */
}

.bmit-container {
    width: 100%;
    max-width: 520px;
    margin: 2rem auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: var(--bmit-text-dark);
    box-sizing: border-box;
}

.bmit-container * {
    box-sizing: border-box;
}

.bmit-card {
    background: var(--bmit-card-bg);
    border-radius: 16px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    border: 1px solid var(--bmit-border);
}

.bmit-header {
    text-align: center;
    margin-bottom: 1.75rem;
}

.bmit-header h2 {
    margin: 0 0 0.5rem 0 !important;
    font-size: 1.75rem !important;
    font-weight: 700 !important;
    color: var(--bmit-text-dark) !important;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.bmit-header h2 i {
    color: var(--bmit-primary);
}

.bmit-header p {
    margin: 0 !important;
    color: var(--bmit-text-light);
    font-size: 0.95rem;
}

/* Tab Switcher Button Styling */
.bmit-toggle-wrapper {
    display: flex;
    background: var(--bmit-bg);
    padding: 4px;
    border-radius: 30px;
    margin-bottom: 1.5rem;
    border: 1px solid var(--bmit-border);
}

.bmit-toggle-btn {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    padding: 10px 16px;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--bmit-text-light);
    cursor: pointer;
    border-radius: 26px;
    transition: all 0.2s ease;
}

.bmit-toggle-btn.active {
    background: #ffffff;
    color: var(--bmit-primary);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

/* Input Fields Setup */
.bmit-inputs-group {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    animation: bmitFadeIn 0.3s ease-in-out;
}

.bmit-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.bmit-input-box {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.bmit-input-box label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--bmit-text-dark);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.bmit-input-box label i {
    color: var(--bmit-text-light);
}

.bmit-input-box input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--bmit-border);
    border-radius: 10px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s ease;
    background: var(--bmit-bg);
}

.bmit-input-box input:focus {
    border-color: var(--bmit-primary);
    background: #ffffff;
}

/* Action Buttons styling */
.bmit-actions {
    margin-top: 1.25rem;
    display: flex;
    justify-content: flex-end;
}

.bmit-btn {
    padding: 10px 18px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: 10px;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.bmit-btn-secondary {
    background: var(--bmit-bg);
    color: var(--bmit-text-dark);
    border: 1px solid var(--bmit-border);
}

.bmit-btn-secondary:hover {
    background: #e2e8f0;
}

/* Error Alert Box */
.bmit-error-msg {
    margin-top: 1rem;
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Result Visualization Cards */
.bmit-result-card {
    margin-top: 1.75rem;
    background: #fafafa;
    border: 1px solid var(--bmit-border);
    border-radius: 12px;
    padding: 1.5rem;
    animation: bmitSlideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.bmit-result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.bmit-result-header h3 {
    margin: 0 !important;
    font-size: 1.15rem !important;
    font-weight: 700;
}

.bmit-copy-btn {
    background: transparent;
    border: none;
    color: var(--bmit-primary);
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    padding: 4px 8px;
    border-radius: 6px;
}

.bmit-copy-btn:hover {
    background: rgba(37, 99, 237, 0.08);
}

.bmit-score-display {
    text-align: center;
    margin-bottom: 1.5rem;
    padding: 1rem;
    border-radius: 10px;
    transition: background-color 0.3s ease;
}

.bmit-score-num {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 0.25rem;
}

.bmit-score-label {
    font-size: 1.15rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Multi-colored CSS Progress Bar Scale */
.bmit-scale-container {
    margin: 1.5rem 0;
}

.bmit-scale-bar {
    height: 14px;
    border-radius: 7px;
    position: relative;
    background: linear-gradient(to right, 
        var(--bmit-underweight) 0%, var(--bmit-underweight) 23%, 
        var(--bmit-normal) 23%, var(--bmit-normal) 54%, 
        var(--bmit-overweight) 54%, var(--bmit-overweight) 77%, 
        var(--bmit-obese) 77%, var(--bmit-obese) 100%
    );
}

.bmit-pointer {
    width: 16px;
    height: 16px;
    background: #ffffff;
    border: 3px solid var(--bmit-text-dark);
    border-radius: 50%;
    position: absolute;
    top: -1px;
    transform: translateX(-50%);
    transition: left 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.bmit-scale-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--bmit-text-light);
    margin-top: 6px;
    padding: 0 4px;
}

/* Suggestions Info Lists */
.bmit-details {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    border-top: 1px solid var(--bmit-border);
    padding-top: 1rem;
}

.bmit-details p {
    margin: 0 !important;
    font-size: 0.9rem !important;
    line-height: 1.4 !important;
    color: #334155;
}

.bmit-details p i {
    width: 18px;
    color: var(--bmit-text-light);
}

/* Status-based Dynamic Utilities styles toggled via JS */
.bmit-status-underweight .bmit-score-num, .bmit-status-underweight .bmit-score-label { color: var(--bmit-underweight); }
.bmit-status-normal .bmit-score-num, .bmit-status-normal .bmit-score-label { color: var(--bmit-normal); }
.bmit-status-overweight .bmit-score-num, .bmit-status-overweight .bmit-score-label { color: var(--bmit-overweight); }
.bmit-status-obese .bmit-score-num, .bmit-status-obese .bmit-score-label { color: var(--bmit-obese); }

.bmit-status-underweight .bmit-score-display { background-color: rgba(59, 130, 246, 0.08); }
.bmit-status-normal .bmit-score-display { background-color: rgba(16, 185, 129, 0.08); }
.bmit-status-overweight .bmit-score-display { background-color: rgba(245, 158, 133, 0.08); }
.bmit-status-obese .bmit-score-display { background-color: rgba(239, 68, 68, 0.08); }

.bmit-hidden {
    display: none !important;
}

/* Responsive Framework & Keyframes */
@keyframes bmitFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes bmitSlideUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@media(max-width: 480px) {
    .bmit-card {
        padding: 1.25rem;
    }
    .bmit-header h2 {
        font-size: 1.5rem !important;
    }
    .bmit-score-num {
        font-size: 2.5rem;
    }
}