/**
 * HealthGrowth.in - Single Calculator Page Stylesheet
 * 100% Mobile Responsive, Clean Clinical Aesthetics
 */

:root {
    --green: #11965b;
    --green-dark: #087b49;
    --green-light: #eaf9f2;
    --navy: #103654;
    --text: #29465d;
    --muted: #678096;
    --border: #dcebf0;
    --white: #ffffff;
    --soft: #f7fcfa;
    --danger: #dc2626;
    --warning: #d97706;
    --info: #0284c7;
}

/* Base Container & Breadcrumbs */
.calc-page-container {
    max-width: 1180px;
    margin: 0 auto;
    padding: 25px 20px 60px;
}

.breadcrumbs {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 13px;
    color: var(--muted);
    margin-bottom: 24px;
}

.breadcrumbs a {
    color: var(--green);
    text-decoration: none;
    font-weight: 500;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

.breadcrumbs span.separator {
    color: #a0b6c6;
}

.breadcrumbs span.current {
    color: var(--navy);
    font-weight: 600;
}

/* Hero Header */
.calc-hero-header {
    background: linear-gradient(135deg, #f3fcf8 0%, #ffffff 100%);
    border: 1px solid #d5ede2;
    border-radius: 16px;
    padding: 32px 28px;
    margin-bottom: 30px;
    position: relative;
    overflow: hidden;
}

.calc-hero-header:before {
    content: "";
    position: absolute;
    right: -20px;
    top: -20px;
    width: 160px;
    height: 160px;
    background: radial-gradient(circle, rgba(17,150,91,0.08) 0%, transparent 70%);
    border-radius: 50%;
}

.badge-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.who-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #ddf7eb;
    color: #087c4b;
    border-radius: 20px;
    padding: 5px 14px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.3px;
}

.cat-badge {
    background: #eef4f8;
    color: var(--navy);
    border-radius: 20px;
    padding: 5px 12px;
    font-size: 12px;
    font-weight: 600;
}

.calc-hero-header h1 {
    font-size: 32px;
    color: var(--navy);
    line-height: 1.25;
    margin-bottom: 12px;
}

.calc-hero-header p {
    color: #4b677d;
    font-size: 15px;
    max-width: 800px;
    line-height: 1.6;
}

/* Calculator Grid (Form + Results) */
.calc-interactive-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    margin-bottom: 36px;
}

@media (max-width: 860px) {
    .calc-interactive-layout {
        grid-template-columns: 1fr;
    }
}

/* Left Card: Input Form */
.calc-card-panel {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 26px;
    box-shadow: 0 4px 20px rgba(16, 54, 84, 0.04);
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #edf4f7;
    padding-bottom: 14px;
    margin-bottom: 20px;
}

.panel-header h2 {
    font-size: 18px;
    color: var(--navy);
    margin: 0;
}

/* Unit Toggle Switcher */
.unit-switcher {
    display: flex;
    background: #edf5f2;
    padding: 3px;
    border-radius: 20px;
}

.unit-toggle-btn {
    border: 0;
    background: transparent;
    padding: 5px 14px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 600;
    color: #527083;
    cursor: pointer;
    transition: 0.2s;
}

.unit-toggle-btn.active {
    background: var(--green);
    color: var(--white);
    box-shadow: 0 2px 6px rgba(17,150,91,0.25);
}

/* Input Fields */
.input-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 500px) {
    .input-grid {
        grid-template-columns: 1fr;
    }
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.input-group.full-width {
    grid-column: 1 / -1;
}

.input-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--navy);
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper input,
.input-wrapper select {
    width: 100%;
    height: 44px;
    border: 1px solid #cce2dc;
    border-radius: 8px;
    padding: 0 14px;
    font-size: 15px;
    color: var(--navy);
    background: #fafdfc;
    transition: 0.2s;
    outline: none;
}

.input-wrapper input:focus,
.input-wrapper select:focus {
    border-color: var(--green);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(17,150,91,0.12);
}

.input-unit {
    position: absolute;
    right: 12px;
    font-size: 12px;
    font-weight: 600;
    color: #7b96a8;
    pointer-events: none;
}

.btn-row {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.btn-primary-calc {
    flex: 2;
    height: 46px;
    background: var(--green);
    color: var(--white);
    border: 0;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.2s;
    box-shadow: 0 4px 12px rgba(17,150,91,0.22);
}

.btn-primary-calc:hover {
    background: var(--green-dark);
    transform: translateY(-1px);
}

.btn-secondary-reset {
    flex: 1;
    height: 46px;
    background: #f1f7f5;
    color: #4b6b5e;
    border: 1px solid #d5e8e1;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
}

.btn-secondary-reset:hover {
    background: #e4efe9;
}

/* Right Card: Result Output */
.result-panel {
    background: linear-gradient(135deg, #fbfefd 0%, #f4fbf8 100%);
    border: 1px solid #c9ebd9;
    border-radius: 14px;
    padding: 26px;
    box-shadow: 0 6px 24px rgba(17,150,91,0.06);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.result-main {
    text-align: center;
    padding: 10px 0 20px;
    border-bottom: 1px solid #d6ece1;
}

.result-heading-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #5c7b8e;
    margin-bottom: 8px;
}

.result-big-value {
    font-size: 44px;
    font-weight: 800;
    color: var(--navy);
    line-height: 1;
    margin-bottom: 4px;
}

.result-unit-label {
    font-size: 16px;
    font-weight: 600;
    color: var(--green);
    margin-bottom: 14px;
}

.status-badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
}

.status-normal {
    background: #d4f4e2;
    color: #067240;
}

.status-warning {
    background: #fef3c7;
    color: #b45309;
}

.status-danger {
    background: #fee2e2;
    color: #b91c1c;
}

/* Gauge Bar */
.gauge-container {
    margin: 20px 0;
}

.gauge-track {
    width: 100%;
    height: 10px;
    background: linear-gradient(to right, #38bdf8, #22c55e, #eab308, #ef4444);
    border-radius: 5px;
    position: relative;
}

.gauge-needle {
    position: absolute;
    top: -4px;
    width: 18px;
    height: 18px;
    background: var(--navy);
    border: 2px solid var(--white);
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    transform: translateX(-50%);
    transition: left 0.4s ease;
}

.gauge-labels {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--muted);
    margin-top: 6px;
}

/* Result Breakdown */
.result-breakdown {
    margin: 16px 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.breakdown-row {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    padding: 6px 0;
    border-bottom: 1px dashed #d8eae2;
}

.breakdown-label {
    color: #4b667a;
}

.breakdown-val {
    color: var(--navy);
    font-weight: 700;
}

.result-summary-text {
    font-size: 13px;
    color: #416253;
    line-height: 1.5;
    background: #eef8f3;
    padding: 12px 14px;
    border-radius: 8px;
    margin-bottom: 14px;
}

.copy-btn {
    width: 100%;
    height: 40px;
    background: var(--white);
    border: 1px solid #b8dfcd;
    color: var(--green-dark);
    font-size: 13px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: 0.2s;
}

.copy-btn:hover {
    background: #eaf8f1;
}

/* Medical Disclaimer Box */
.medical-disclaimer-box {
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-left: 5px solid #d97706;
    border-radius: 10px;
    padding: 18px 20px;
    margin-bottom: 36px;
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.disclaimer-icon {
    font-size: 24px;
    line-height: 1;
}

.disclaimer-body strong {
    display: block;
    color: #92400e;
    font-size: 14px;
    margin-bottom: 4px;
}

.disclaimer-body p {
    color: #78350f;
    font-size: 13px;
    line-height: 1.5;
    margin: 0;
}

/* SEO Article Section */
.calc-seo-article {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 36px 32px;
    box-shadow: 0 4px 20px rgba(16, 54, 84, 0.03);
    margin-bottom: 40px;
    color: var(--text);
}

.article-section {
    margin-bottom: 32px;
}

.calc-seo-article h2 {
    font-size: 22px;
    color: var(--navy);
    margin-bottom: 14px;
    padding-bottom: 8px;
    border-bottom: 2px solid #eef5f3;
}

.calc-seo-article h3 {
    font-size: 17px;
    color: var(--navy);
    margin: 20px 0 10px;
}

.calc-seo-article p {
    font-size: 15px;
    line-height: 1.7;
    color: #385368;
    margin-bottom: 14px;
}

.calc-seo-article ul,
.calc-seo-article ol {
    margin: 12px 0 16px 24px;
    color: #385368;
    font-size: 14px;
    line-height: 1.7;
}

.calc-seo-article li {
    margin-bottom: 8px;
}

/* Formula Box */
.formula-box {
    background: #f4fbf7;
    border: 1px solid #cbe9dc;
    border-radius: 10px;
    padding: 16px 20px;
    margin: 16px 0 20px;
}

.formula-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--green-dark);
    margin-bottom: 6px;
}

.formula-code code {
    font-family: Consolas, Monaco, "Courier New", monospace;
    font-size: 14px;
    font-weight: 600;
    color: var(--navy);
    word-break: break-all;
}

/* Clinical Table */
.table-responsive {
    overflow-x: auto;
    margin: 16px 0;
}

.clinical-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    text-align: left;
}

.clinical-table th {
    background: #edf6f2;
    color: var(--navy);
    font-weight: 700;
    padding: 12px 14px;
    border: 1px solid #d8ede3;
}

.clinical-table td {
    padding: 10px 14px;
    border: 1px solid #e2f0e9;
    color: #385368;
}

.clinical-table tr:nth-child(even) {
    background: #fbfefd;
}

.table-caption {
    display: block;
    color: var(--muted);
    font-size: 11px;
    margin-top: 6px;
}

.worked-example {
    background: #f0f7fb;
    border-left: 4px solid #0284c7;
    padding: 14px 16px;
    border-radius: 6px;
    font-size: 13px;
    color: #0c4a6e;
    margin-top: 14px;
    line-height: 1.6;
}

/* FAQ Accordion / Cards */
.faq-item {
    background: #fafdfc;
    border: 1px solid #e1efe9;
    border-radius: 10px;
    padding: 18px 20px;
    margin-bottom: 12px;
}

.faq-question {
    font-size: 15px;
    color: var(--navy);
    font-weight: 700;
    margin: 0 0 8px;
}

.faq-answer p {
    font-size: 14px;
    color: #4b667a;
    line-height: 1.6;
    margin: 0;
}

/* Editorial Review Box */
.editorial-box {
    display: flex;
    align-items: center;
    gap: 16px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 16px 20px;
    margin-top: 30px;
}

.editorial-icon {
    font-size: 28px;
}

.editorial-content strong {
    display: block;
    color: var(--navy);
    font-size: 13px;
    margin-bottom: 2px;
}

.editorial-content p {
    font-size: 12px;
    color: var(--muted);
    margin: 0;
    line-height: 1.4;
}

/* Related Calculators Grid */
.related-calcs-section {
    margin-top: 40px;
}

.related-calcs-section h2 {
    font-size: 22px;
    color: var(--navy);
    margin-bottom: 16px;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}

@media (max-width: 900px) {
    .related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .related-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
    }
    .related-card { padding: 10px 8px !important; }
    .related-card h3 { font-size: 12px !important; }
    .related-card p { font-size: 10px !important; }
    .calc-hero-header h1 {
        font-size: 24px;
    }
    .result-big-value {
        font-size: 34px;
    }
}

.related-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 16px;
    text-decoration: none;
    color: inherit;
    transition: 0.2s;
    display: flex;
    flex-direction: column;
}

.related-card:hover {
    transform: translateY(-3px);
    border-color: #8bd1b2;
    box-shadow: 0 8px 20px rgba(17,150,91,0.08);
}

.related-icon {
    font-size: 22px;
    margin-bottom: 8px;
}

.related-card h3 {
    font-size: 14px;
    color: var(--navy);
    margin-bottom: 4px;
}

.related-card p {
    font-size: 11px;
    color: var(--muted);
    line-height: 1.4;
    margin-bottom: 8px;
    flex: 1;
}

.related-link {
    color: var(--green);
    font-size: 12px;
    font-weight: 700;
}