/* Blood Pressure Calculator Styles */
.bp-calculator-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Hero Section */
.calc-hero {
    background: linear-gradient(135deg, #e53e3e 0%, #c53030 100%);
    color: white;
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    margin-bottom: 30px;
}

.calc-hero h2 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

.calc-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 30px;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 30px;
}

.stat {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.stat-icon {
    font-size: 2rem;
}

.stat-text {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Calculator Section */
.calc-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.calc-inputs {
    background: #f8f9fa;
    padding: 30px;
    border-radius: 15px;
    border: 2px solid #e9ecef;
}

.calc-inputs h3 {
    color: #2c3e50;
    margin-bottom: 25px;
    font-size: 1.5rem;
}

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #34495e;
}

.input-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #ddd;
    border-radius: 10px;
    font-size: 1.1rem;
    transition: border-color 0.3s ease;
}

.input-group input:focus {
    outline: none;
    border-color: #e53e3e;
    box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.1);
}

.input-group small {
    display: block;
    color: #7f8c8d;
    margin-top: 5px;
    font-size: 0.9rem;
}

.bp-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.calc-btn {
    width: 100%;
    background: linear-gradient(45deg, #e53e3e, #c53030);
    color: white;
    border: none;
    padding: 15px 20px;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.calc-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(229, 62, 62, 0.4);
}

.calc-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* Results Section */
.calc-results {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border: 2px solid #e9ecef;
}

.result-header {
    text-align: center;
    margin-bottom: 30px;
}

.result-header h3 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.bp-reading {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.bp-category {
    font-size: 1.3rem;
    font-weight: 600;
    padding: 10px 20px;
    border-radius: 25px;
    margin-bottom: 20px;
    display: inline-block;
}

/* Blood Pressure Categories */
.normal {
    background: #d4edda;
    color: #155724;
}

.elevated {
    background: #fff3cd;
    color: #856404;
}

.high-stage1 {
    background: #f8d7da;
    color: #721c24;
}

.high-stage2 {
    background: #f5c6cb;
    color: #491217;
}

.hypertensive-crisis {
    background: #d1ecf1;
    color: #0c5460;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.result-description {
    font-size: 1.1rem;
    color: #6c757d;
    line-height: 1.6;
}

/* BP Chart Container */
.bp-chart-container {
    margin-top: 30px;
    background: white;
    padding: 20px;
    border-radius: 15px;
    border: 1px solid #e9ecef;
}

.chart-canvas {
    max-height: 300px;
}

/* Health Recommendations */
.health-recommendations {
    margin-top: 30px;
    padding: 25px;
    background: #f8f9fa;
    border-radius: 15px;
    border-left: 5px solid #e53e3e;
}

.health-recommendations h4 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.recommendations-list {
    display: grid;
    gap: 10px;
}

.recommendation-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: white;
    border-radius: 8px;
    border-left: 3px solid #28a745;
}

.recommendation-icon {
    font-size: 1.2rem;
    color: #28a745;
}

.recommendation-text {
    color: #495057;
    font-weight: 500;
}

/* Expert Insights Section */
.expert-insights {
    background: linear-gradient(135deg, #fee 0%, #fef5f5 100%);
    border: 2px solid #fbd5d5;
    border-radius: 15px;
    padding: 35px;
    margin-bottom: 30px;
    box-shadow: 0 5px 20px rgba(229, 62, 62, 0.1);
}

.expert-insights h3 {
    color: #c53030;
    font-size: 1.8rem;
    margin-bottom: 20px;
    text-align: center;
}

.insight-content p {
    color: #2c3e50;
    line-height: 1.8;
    margin-bottom: 18px;
    font-size: 1.05rem;
    text-align: justify;
}

.insight-content p:last-child {
    margin-bottom: 0;
}

/* Educational Content */
.calc-education {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.education-tabs {
    display: flex;
    background: #f1f3f4;
    overflow-x: auto;
}

.tab-btn {
    flex: 1;
    padding: 15px 10px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s ease;
    white-space: nowrap;
    min-width: 120px;
}

.tab-btn.active {
    background: white;
    color: #e53e3e;
    border-bottom: 3px solid #e53e3e;
}

.tab-content {
    display: none;
    padding: 30px;
}

.tab-content.active {
    display: block;
}

.tab-content h4 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 1.5rem;
}

/* Understanding Tab */
.understanding-intro {
    margin-bottom: 30px;
}

.understanding-intro p {
    color: #34495e;
    line-height: 1.7;
    margin-bottom: 20px;
    text-align: justify;
}

.understanding-grid {
    display: grid;
    gap: 25px;
    margin-top: 20px;
}

.info-section {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 10px;
    border-left: 5px solid #e53e3e;
}

.info-section h5 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.info-section p {
    color: #34495e;
    line-height: 1.7;
    margin-bottom: 15px;
    text-align: justify;
}

.info-section p:last-child {
    margin-bottom: 0;
}

/* BP Categories Guide */
.bp-categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.bp-category-card {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 15px;
    border-left: 5px solid;
    transition: transform 0.2s ease;
}

.bp-category-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.bp-category-card.normal-card {
    border-left-color: #28a745;
}

.bp-category-card.elevated-card {
    border-left-color: #ffc107;
}

.bp-category-card.stage1-card {
    border-left-color: #fd7e14;
}

.bp-category-card.stage2-card {
    border-left-color: #dc3545;
}

.bp-category-card.crisis-card {
    border-left-color: #6f42c1;
}

.category-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.category-icon {
    font-size: 1.5rem;
}

.category-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2c3e50;
}

.category-range {
    font-size: 1rem;
    font-weight: 600;
    color: #495057;
    margin-bottom: 10px;
}

.category-description {
    color: #6c757d;
    line-height: 1.5;
}

/* Lifestyle Content */
.lifestyle-intro {
    margin-bottom: 30px;
}

.lifestyle-intro p {
    color: #34495e;
    line-height: 1.7;
    margin-bottom: 20px;
    text-align: justify;
}

.lifestyle-strategies {
    display: grid;
    gap: 30px;
    margin-top: 20px;
}

.strategy-section {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 10px;
    border-left: 5px solid #e53e3e;
}

.strategy-section h5 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.strategy-section p {
    color: #34495e;
    line-height: 1.7;
    margin-bottom: 15px;
    text-align: justify;
}

.strategy-section p:last-child {
    margin-bottom: 0;
}

.lifestyle-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.lifestyle-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    border-left: 5px solid;
}

.diet-section {
    border-left-color: #28a745;
}

.exercise-section {
    border-left-color: #17a2b8;
}

.stress-section {
    border-left-color: #6f42c1;
}

.lifestyle-section h5 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.lifestyle-tips {
    display: grid;
    gap: 10px;
}

.tip-item {
    background: white;
    padding: 12px 15px;
    border-radius: 8px;
    border-left: 3px solid;
    display: flex;
    align-items: center;
    gap: 12px;
}

.tip-item.diet-tip {
    border-left-color: #28a745;
}

.tip-item.exercise-tip {
    border-left-color: #17a2b8;
}

.tip-item.stress-tip {
    border-left-color: #6f42c1;
}

.tip-icon {
    font-size: 1.1rem;
    color: #495057;
}

.tip-text {
    color: #495057;
    font-weight: 500;
}

/* Monitoring Content */
.monitoring-guide {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.monitoring-card {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    border-left: 5px solid #17a2b8;
}

.monitoring-card h5 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.monitoring-steps {
    display: grid;
    gap: 12px;
}

.monitoring-step {
    background: white;
    padding: 12px;
    border-radius: 8px;
    border-left: 3px solid #17a2b8;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.step-number {
    background: #17a2b8;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 600;
    flex-shrink: 0;
}

.step-text {
    color: #495057;
    line-height: 1.4;
}

/* Emergency Content */
.emergency-warning {
    background: #f8d7da;
    border: 2px solid #dc3545;
    padding: 25px;
    border-radius: 15px;
    margin-bottom: 25px;
}

.emergency-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.emergency-icon {
    font-size: 2rem;
    color: #dc3545;
    animation: pulse 2s infinite;
}

.emergency-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #721c24;
    margin: 0;
}

.emergency-symptoms {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.symptom-card {
    background: white;
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid #dc3545;
}

.symptom-card h6 {
    color: #721c24;
    margin-bottom: 5px;
    font-weight: 600;
}

.symptom-description {
    color: #495057;
    font-size: 0.9rem;
    line-height: 1.4;
}

.emergency-action {
    background: #721c24;
    color: white;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    margin-top: 20px;
}

.emergency-action h5 {
    color: white;
    margin-bottom: 10px;
}

.emergency-phone {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 10px;
}

/* Call to Action */
.calc-cta {
    background: linear-gradient(135deg, #e53e3e 0%, #c53030 100%);
    color: white;
    padding: 40px;
    border-radius: 15px;
    text-align: center;
    margin-bottom: 30px;
}

.calc-cta h3 {
    font-size: 2rem;
    margin-bottom: 15px;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 25px;
}

.cta-btn {
    padding: 12px 25px;
    border: none;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.cta-btn.primary {
    background: white;
    color: #e53e3e;
}

.cta-btn.secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.cta-btn:hover {
    transform: translateY(-2px);
}

/* Disclaimer */
.calc-disclaimer {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
}

.calc-disclaimer p {
    margin: 0;
    color: #856404;
    font-size: 0.9rem;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .calc-section {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .calc-hero h2 {
        font-size: 2rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 15px;
    }
    
    .education-tabs {
        flex-direction: column;
    }
    
    .cta-buttons {
        flex-direction: column;
    }
    
    .bp-categories-grid {
        grid-template-columns: 1fr;
    }
    
    .lifestyle-content {
        grid-template-columns: 1fr;
    }
    
    .monitoring-guide {
        grid-template-columns: 1fr;
    }
    
    .emergency-symptoms {
        grid-template-columns: 1fr;
    }
    
    .bp-inputs {
        grid-template-columns: 1fr;
    }
    
    .bp-reading {
        font-size: 2rem;
    }
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(229, 62, 62, 0.3);
    border-radius: 50%;
    border-top-color: #e53e3e;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Share Button */
.share-result {
    background: #17a2b8;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
    margin-top: 15px;
    transition: background 0.3s ease;
}

.share-result:hover {
    background: #138496;
}

/* BP Tracker */
.bp-tracker {
    background: #e8f4fd;
    padding: 20px;
    border-radius: 10px;
    margin-top: 20px;
    border-left: 5px solid #17a2b8;
}

.tracker-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
}

.tracker-icon {
    font-size: 1.5rem;
    color: #17a2b8;
}

.tracker-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.tracker-description {
    color: #6c757d;
    margin-bottom: 15px;
    line-height: 1.5;
}

.tracker-button {
    background: #17a2b8;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s ease;
}

.tracker-button:hover {
    background: #138496;
}