/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
.navbar {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 20px;
}

.logo a {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2563eb;
    text-decoration: none;
    transition: color 0.3s ease;
}

.logo a:hover {
    color: #1d4ed8;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    color: #64748b;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    padding: 0.5rem 0;
    position: relative;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: #2563eb;
}

.nav-menu a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background-color: #2563eb;
}

/* Mobile Navigation */
@media (max-width: 768px) {
    .navbar .container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 4rem 0;
    text-align: center;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background-color: #2563eb;
    color: #fff;
}

.btn-primary:hover {
    background-color: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
}

.btn-secondary {
    background-color: #fff;
    color: #2563eb;
}

.btn-secondary:hover {
    background-color: #f1f5f9;
    transform: translateY(-2px);
}

.button-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Content Sections */
.content-section {
    padding: 3rem 0;
}

.calculator-section {
    padding: 2rem 0;
}

.calculator-section h1 {
    font-size: 2.5rem;
    color: #1e293b;
    margin-bottom: 0.5rem;
    text-align: center;
}

.subtitle {
    text-align: center;
    color: #64748b;
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

/* Calculator Card */
.calculator-card {
    background: #fff;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    margin-bottom: 3rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #334155;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #2563eb;
}

.form-group small {
    display: block;
    margin-top: 0.25rem;
    color: #64748b;
    font-size: 0.875rem;
}

.radio-group {
    display: flex;
    gap: 2rem;
}

.radio-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: normal;
}

.input-row {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.input-row input {
    flex: 1;
}

/* Result Box */
.result-box {
    background: #f8fafc;
    border-left: 4px solid #2563eb;
    padding: 2rem;
    border-radius: 8px;
    margin-top: 2rem;
}

.result-box h3 {
    margin-bottom: 1.5rem;
    color: #1e293b;
}

.result-value {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #fff;
    border-radius: 6px;
}

.result-value .label {
    font-weight: 600;
    color: #475569;
}

.result-value .value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2563eb;
}

.result-category {
    text-align: center;
    margin: 1.5rem 0;
}

.category-badge {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-weight: 700;
    font-size: 1.1rem;
}

.category-underweight {
    background-color: #fef3c7;
    color: #92400e;
}

.category-normal {
    background-color: #d1fae5;
    color: #065f46;
}

.category-overweight {
    background-color: #fed7aa;
    color: #9a3412;
}

.category-obese {
    background-color: #fecaca;
    color: #991b1b;
}

.guidance-text {
    background: #fff;
    padding: 1rem;
    border-radius: 6px;
    margin-top: 1rem;
    line-height: 1.8;
}

/* BMI Chart */
.bmi-chart {
    margin-top: 2rem;
}

.chart-bar {
    height: 40px;
    background: linear-gradient(to right, #fbbf24 0%, #10b981 25%, #10b981 50%, #f59e0b 75%, #ef4444 100%);
    border-radius: 20px;
    position: relative;
    margin-bottom: 0.5rem;
}

.indicator {
    position: absolute;
    top: -5px;
    width: 4px;
    height: 50px;
    background: #1e293b;
    transform: translateX(-2px);
    transition: left 0.3s ease;
}

.indicator::after {
    content: '▼';
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    color: #1e293b;
}

.chart-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.875rem;
    color: #64748b;
    text-align: center;
}

.chart-labels span {
    flex: 1;
}

/* Calorie Goals */
.calorie-goals {
    background: #fff;
    border-radius: 6px;
    padding: 1rem;
    margin-top: 1rem;
}

.goal-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    border-bottom: 1px solid #e2e8f0;
}

.goal-item:last-child {
    border-bottom: none;
}

.goal-label {
    font-weight: 500;
    color: #475569;
}

.goal-value {
    font-weight: 700;
    color: #2563eb;
    font-size: 1.1rem;
}

/* Article Styling */
.main-article {
    background: #fff;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.main-article h1 {
    font-size: 2.5rem;
    color: #1e293b;
    margin-bottom: 1.5rem;
}

.main-article h2 {
    font-size: 2rem;
    color: #1e293b;
    margin: 2rem 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e2e8f0;
}

.main-article h3 {
    font-size: 1.5rem;
    color: #334155;
    margin: 1.5rem 0 1rem;
}

.main-article p {
    margin-bottom: 1rem;
    line-height: 1.8;
}

.main-article ul {
    margin-bottom: 1rem;
    padding-left: 2rem;
}

.main-article li {
    margin-bottom: 0.5rem;
    line-height: 1.8;
}

.main-article a {
    color: #2563eb;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s ease;
}

.main-article a:hover {
    border-bottom-color: #2563eb;
}

/* CTA Box */
.cta-box {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    margin: 3rem 0;
}

.cta-box h3 {
    margin-bottom: 1rem;
}

.cta-box .btn {
    margin: 0.5rem;
}

/* FAQ Section */
.faq-section {
    margin-top: 2rem;
}

.faq-item {
    background: #f8fafc;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    border-left: 4px solid #2563eb;
}

.faq-item h3 {
    color: #1e293b;
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}

.faq-item p {
    color: #475569;
    line-height: 1.7;
}

/* Contact Form */
.contact-form-container {
    background: #fff;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    margin: 2rem 0;
}

.contact-form textarea {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 1rem;
    font-family: inherit;
    resize: vertical;
}

.contact-form textarea:focus {
    outline: none;
    border-color: #2563eb;
}

.form-message {
    margin-top: 1rem;
    padding: 1rem;
    border-radius: 6px;
}

.form-message.success {
    background-color: #d1fae5;
    color: #065f46;
}

.form-message.error {
    background-color: #fee2e2;
    color: #991b1b;
}

/* Legal Content */
.legal-content h2 {
    margin-top: 2.5rem;
}

.legal-content h3 {
    margin-top: 1.5rem;
    color: #475569;
    font-size: 1.25rem;
}

/* Footer */
footer {
    background-color: #1e293b;
    color: #cbd5e1;
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    color: #fff;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: #cbd5e1;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: #fff;
}

.footer-section p {
    line-height: 1.6;
    font-size: 0.9rem;
}

.footer-bottom {
    border-top: 1px solid #334155;
    padding-top: 1.5rem;
    text-align: center;
    color: #94a3b8;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 1.75rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .calculator-section h1 {
        font-size: 2rem;
    }
    
    .main-article h1 {
        font-size: 2rem;
    }
    
    .main-article h2 {
        font-size: 1.5rem;
    }
    
    .main-article {
        padding: 1.5rem;
    }
    
    .calculator-card {
        padding: 1.5rem;
    }
    
    .radio-group {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .cta-buttons {
        flex-direction: column;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
}

/* Print Styles */
@media print {
    .navbar, footer, .cta-box {
        display: none;
    }
    
    .result-box {
        page-break-inside: avoid;
    }
}
