/* VKI Calculator - Simple Medical Theme */

/* Base Styles */
#vki-calculator-wrapper {
    max-width: 900px;
    margin: 40px auto;
    padding: 30px;
    font-family: inherit;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border: 1px solid #e9ecef;
}

/* Header */
.vki-header {
    text-align: center;
    padding: 25px 20px;
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    margin: -30px -30px 30px -30px;
    border-radius: 10px 10px 0 0;
}

.vki-header h3 {
    margin: 0 0 10px 0;
    font-size: 1.8rem;
    font-weight: 700;
}

.vki-header p {
    margin: 0;
    font-size: 1rem;
}

/* Gender Selection */
.gender-selection {
    margin-bottom: 25px;
}

.gender-selection .form-label {
    font-weight: 600;
    color: #495057;
    font-size: 1.1rem;
}

.gender-btn {
    font-weight: 600;
    padding: 12px 30px;
    min-width: 120px;
    border-width: 2px;
}

.gender-btn.active {
    background-color: #28a745 !important;
    border-color: #28a745 !important;
    color: white !important;
}

/* Form Controls */
.form-control {
    padding: 12px 15px !important;
    border: 2px solid #e9ecef !important;
    border-radius: 8px !important;
    font-size: 1rem !important;
    font-weight: 500 !important;
    transition: all 0.3s ease !important;
    background: #fff !important;
}

.form-control:focus {
    border-color: #28a745 !important;
    box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.1) !important;
    transform: translateY(-1px) !important;
}

.form-control.error {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1) !important;
}

.form-text.text-muted {
    font-size: 0.85rem !important;
    color: #6c757d !important;
    margin-top: 5px !important;
}

/* Green Button */
.btn-green {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
    border: none !important;
    color: white !important;
    padding: 12px 30px !important;
    font-size: 1.1rem !important;
    font-weight: 700 !important;
    border-radius: 8px !important;
    transition: all 0.3s ease !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
}

.btn-green:hover {
    background: linear-gradient(135deg, #1e7e34 0%, #17a2b8 100%) !important;
    color: white !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.3) !important;
}

.btn-green:focus {
    box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.25) !important;
    color: white !important;
}

/* Result Section - Hidden by default */
.result-section {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    background: #f8f9fa;
    padding: 25px;
    border-radius: 10px;
    margin-top: 30px;
    border: 1px solid #e9ecef;
    height: 0 !important;
    overflow: hidden !important;
}

.result-section.show {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    overflow: visible !important;
    animation: fadeInUp 0.5s ease;
}

#vki-result:not(.show) {
    display: none !important;
    visibility: hidden !important;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* BMI Display */
.result-header {
    margin-bottom: 25px;
}

.bmi-display {
    font-size: 3.5rem;
    font-weight: 800;
    color: #2c3e50;
    margin-bottom: 8px;
}

.bmi-unit {
    font-size: 1rem;
    color: #6c757d;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 15px;
}

.bmi-category {
    font-size: 1.3rem;
    font-weight: 700;
    padding: 10px 20px;
    border-radius: 20px;
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.bmi-category.underweight {
    background: #17a2b8;
    color: white;
}

.bmi-category.normal {
    background: #28a745;
    color: white;
}

.bmi-category.overweight {
    background: #ffc107;
    color: #212529;
}

.bmi-category.obese1,
.bmi-category.obese2,
.bmi-category.obese3 {
    background: #dc3545;
    color: white;
}

/* Result Details */
.result-details {
    margin-bottom: 25px;
}

.detail-item {
    background: white;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    border: 1px solid #e9ecef;
}

.detail-item strong {
    color: #2c3e50;
    display: block;
    margin-bottom: 5px;
}

.detail-item span {
    color: #28a745;
    font-weight: 600;
}

.recommendation-box {
    background: #e8f5e8;
    border: 1px solid #28a745;
    border-radius: 8px;
    padding: 15px;
}

.recommendation-box p {
    margin: 0;
    color: #155724;
    line-height: 1.5;
    font-weight: 500;
}

/* BMI Classification Table */
.bmi-classification h6 {
    color: #2c3e50;
    font-weight: 700;
}

.table {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.table th {
    background: #2c3e50 !important;
    color: white !important;
    font-weight: 600;
    border: none !important;
    padding: 12px 8px !important;
    font-size: 0.9rem;
}

.table td {
    padding: 10px 8px !important;
    vertical-align: middle !important;
    border-color: #e9ecef !important;
    font-size: 0.9rem;
}

.bmi-row.highlighted {
    background: #e8f5e8 !important;
    font-weight: 600;
}

.bmi-row.highlighted td {
    border-color: #28a745 !important;
    color: #155724 !important;
}

/* Medical Warning */
.medical-warning {
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 6px;
    padding: 12px;
    text-align: center;
}

.medical-warning small {
    color: #856404;
    line-height: 1.4;
}

/* Responsive Design */
@media (max-width: 768px) {
    #vki-calculator-wrapper {
        margin: 20px;
        padding: 20px;
        border-radius: 8px;
    }
    
    .vki-header {
        margin: -20px -20px 25px -20px;
        padding: 20px 15px;
        border-radius: 8px 8px 0 0;
    }
    
    .vki-header h3 {
        font-size: 1.5rem;
    }
    
    .vki-header p {
        font-size: 0.9rem;
    }
    
    .gender-btn {
        padding: 10px 20px;
        min-width: 100px;
        font-size: 0.95rem;
    }
    
    .bmi-display {
        font-size: 2.8rem;
    }
    
    .table th,
    .table td {
        padding: 8px 6px !important;
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .vki-header h3 {
        font-size: 1.3rem;
    }
    
    .vki-header p {
        font-size: 0.85rem;
    }
    
    .gender-btn {
        padding: 8px 15px;
        min-width: 90px;
        font-size: 0.9rem;
    }
    
    .bmi-display {
        font-size: 2.5rem;
    }
    
    .form-control {
        padding: 10px 12px !important;
        font-size: 0.95rem !important;
    }
    
    .btn-green {
        padding: 10px 25px !important;
        font-size: 1rem !important;
    }
    
    .table {
        font-size: 0.75rem;
    }
    
    .table th,
    .table td {
        padding: 6px 4px !important;
        font-size: 0.75rem;
    }
}

/* Focus States */
.btn:focus {
    outline: none !important;
}

/* Print Styles */
@media print {
    #vki-calculator-wrapper {
        box-shadow: none;
        border: 1px solid #000;
        margin: 0;
        break-inside: avoid;
    }
    
    .vki-header {
        background: #f8f9fa !important;
        color: #000 !important;
        -webkit-print-color-adjust: exact;
    }
    
    .btn {
        display: none;
    }
    
    .result-section {
        opacity: 1 !important;
        transform: none !important;
    }
}
