/* Jedyny system layoutu stron narzędzi. Ładowany po output.css. */
.tool-page-main,.tool-page-content,.tool-calculator-section,.tool-container{width:100%}
.tool-container{max-width:64rem;margin-inline:auto;padding-inline:1rem}
.tool-affiliate-container{padding-block:0 1.5rem}
.tool-intro-section{border-bottom:0!important;box-shadow:none!important;background:var(--ob-bg)}
.tool-intro-inner{padding-block:1.5rem 1.25rem}
.tool-title{margin:.5rem 0 0;color:var(--ob-text);font-size:clamp(1.75rem,4vw,2.35rem);font-weight:700;line-height:1.12;letter-spacing:-.025em}
.tool-title-row{display:flex;align-items:baseline;gap:1.5rem;flex-wrap:wrap}
.tool-updated-at{margin:0;color:var(--ob-text-muted);font-size:.75rem;line-height:1.4}
.tool-description{max-width:52rem;margin:.5rem 0 0;color:var(--ob-text-secondary);font-size:.9rem;line-height:1.55}
.tool-calculator-section{padding-block:1.25rem 2rem;background:var(--ob-bg)}
.tool-calculator-shell{width:100%;overflow:hidden;border:1px solid var(--ob-border);border-radius:1rem;background:var(--ob-surface);box-shadow:0 2px 8px rgba(15,23,42,.04)}
.tool-calculator-shell-body{width:100%;min-width:0}
/* Nawigacja grupy kalkulatorów zdrowia i wagi. */
.tool-calculator-shell .health-weight-tabs{
    display:grid;
    grid-template-columns:repeat(6,minmax(0,1fr));
    width:100%;
    overflow:hidden;
    border-bottom:1px solid var(--ob-border);
    background:var(--ob-surface);
}

.tool-calculator-shell .health-weight-tab{
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    gap:.2rem;
    min-width:0;
    grid-column:span 2;
    min-height:4.2rem;
    padding:.65rem .45rem;
    border:0;
    border-bottom:3px solid transparent;
    color:var(--ob-text-secondary);
    background:transparent;
    text-align:center;
    text-decoration:none;
    font-size:.8rem;
    line-height:1.35;
    transition:background-color .15s ease,color .15s ease;
}
.tool-calculator-shell .health-weight-tab span:first-child{font-weight:600}
.tool-calculator-shell .health-weight-tab span:last-child{font-size:.74rem}
.tool-calculator-shell .health-weight-tab[aria-current=page]{
    border-bottom-color:var(--ob-primary);
    color:var(--ob-primary);
    background:var(--ob-surface-soft);
    font-weight:700;
}
.tool-calculator-shell .health-weight-tab:hover{
    color:var(--ob-primary);
    background:var(--ob-surface-soft);
}
.tool-calculator-shell .body-index-tabs{
    display:grid;
    grid-template-columns:repeat(6,minmax(0,1fr));
    gap:0;
    padding:0;
    overflow:hidden;
    border:0;
    border-bottom:1px solid var(--ob-border);
    border-radius:0;
    background:var(--ob-surface);
}
.tool-calculator-shell .body-index-tabs .body-index-tab{
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    gap:.2rem;
    min-width:0;
    grid-column:span 2;
    min-height:4.2rem;
    padding:.65rem .45rem;
    border:0;
    border-bottom:2px solid transparent;
    border-radius:0;
    color:var(--ob-text-secondary);
    background:transparent;
    text-decoration:none;
    font-size:.8rem;
    font-weight:400;
    line-height:1.35;
    text-align:center;
    transition:background-color .15s ease,color .15s ease;
}
.tool-calculator-shell .body-index-tabs .body-index-tab span:first-child{font-weight:600}
.tool-calculator-shell .body-index-tabs .body-index-tab span:last-child{font-size:.74rem;font-weight:500}
.tool-calculator-shell .body-index-tabs .body-index-tab[aria-selected=true]{
    border:0!important;
    border-bottom:3px solid var(--ob-primary)!important;
    border-radius:0!important;
    color:var(--ob-primary)!important;
    background:var(--ob-surface-soft)!important;
    box-shadow:none!important;
    font-weight:700;
}
.tool-calculator-shell .body-index-tabs .body-index-tab:hover{
    color:var(--ob-primary);
    background:var(--ob-surface-soft)!important;
}
.tool-calculator-shell :is(.health-weight-tabs,.body-index-tabs,[role=tablist]) > :nth-child(3n + 1):nth-last-child(2),
.tool-calculator-shell :is(.health-weight-tabs,.body-index-tabs,[role=tablist]) > :nth-child(3n + 1):nth-last-child(2) ~ *{grid-column:span 3}
.tool-calculator-shell :is(.health-weight-tabs,.body-index-tabs,[role=tablist]) > :nth-child(3n + 1):last-child{grid-column:3 / span 2}
.tool-calculator-shell :is(.health-weight-tabs,.body-index-tabs,[role=tablist]) > :nth-child(1):nth-last-child(4),
.tool-calculator-shell :is(.health-weight-tabs,.body-index-tabs,[role=tablist]) > :nth-child(1):nth-last-child(4) ~ *{grid-column:span 3}
@media(max-width:640px){
    .tool-calculator-shell .health-weight-tabs,
    .tool-calculator-shell .body-index-tabs,
    .tool-calculator-shell [role=tablist]{
        grid-template-columns:repeat(6,minmax(0,1fr));
        gap:.4rem;
        padding:.65rem;
        border:0;
        background:var(--ob-surface);
    }
    .tool-calculator-shell .health-weight-tab,
    .tool-calculator-shell .body-index-tabs .body-index-tab,
    .tool-calculator-shell [role=tablist] > [role=tab]{
        box-sizing:border-box;
        min-width:0;
        min-height:4.25rem;
        padding:.55rem .35rem;
        overflow-wrap:anywhere;
        border:1px solid var(--ob-border);
        border-radius:.65rem;
        background:var(--ob-surface-soft);
        font-size:.78rem;
        line-height:1.25;
    }
    .tool-calculator-shell .health-weight-tab span,
    .tool-calculator-shell .body-index-tabs .body-index-tab span,
    .tool-calculator-shell [role=tablist] > [role=tab] span{max-width:100%;overflow-wrap:anywhere}
    .tool-calculator-shell .health-weight-tab span:last-child,
    .tool-calculator-shell .body-index-tabs .body-index-tab span:last-child{font-size:.68rem}
    .tool-calculator-shell .health-weight-tab[aria-current=page],
    .tool-calculator-shell .body-index-tabs .body-index-tab[aria-selected=true]{
        border:1px solid var(--ob-primary)!important;
        border-bottom:1px solid var(--ob-primary)!important;
        border-radius:.65rem!important;
        background:var(--ob-surface-soft)!important;
        box-shadow:inset 0 0 0 1px var(--ob-primary)!important;
    }
    .tool-calculator-shell .health-weight-tab:hover,
    .tool-calculator-shell .health-weight-tab:focus-visible,
    .tool-calculator-shell .body-index-tabs .body-index-tab:hover,
    .tool-calculator-shell .body-index-tabs .body-index-tab:focus-visible,
    .tool-calculator-shell [role=tablist] > [role=tab]:hover,
    .tool-calculator-shell [role=tablist] > [role=tab]:focus-visible{
        border-color:var(--ob-primary)!important;
        color:var(--ob-primary)!important;
        background:var(--ob-surface-soft)!important;
        box-shadow:inset 0 0 0 1px var(--ob-primary)!important;
    }
}

.tool-calculator-shell [role=tablist]{display:grid;width:100%;grid-template-columns:repeat(6,minmax(0,1fr));border-bottom:1px solid var(--ob-border);background:var(--ob-surface)}
.tool-calculator-shell [role=tab]{grid-column:span 2;min-width:0;min-height:4.2rem;padding:.65rem .45rem;border:0;border-bottom:3px solid transparent;color:var(--ob-text-secondary);background:transparent;font-size:.8rem;font-weight:400;line-height:1.35;text-align:center}
.tool-calculator-shell [role=tab][aria-selected=true]{border-bottom:3px solid var(--ob-primary)!important;color:var(--ob-primary)!important;background:var(--ob-surface-soft)!important;font-weight:700!important;box-shadow:none}
.tool-calculator-shell [role=tab]:hover{color:var(--ob-primary);background:var(--ob-surface-soft)}
.tool-calculator-shell :is(.health-weight-tab,.body-index-tab):is([aria-current=page],[aria-selected=true]){color:var(--ob-primary)!important;background:var(--ob-surface-soft)!important}
.tool-calculator-shell :is(.health-weight-tab,.body-index-tab):is(:hover,:focus-visible){color:var(--ob-primary)!important;background:var(--ob-surface-soft)!important}
html[data-theme="dark"] .tool-calculator-shell :is(.body-index-tabs .body-index-tab[aria-selected="true"],.body-index-tabs .body-index-tab:hover,.body-index-tabs .body-index-tab:focus-visible,[role=tablist] > [role=tab][aria-selected="true"],[role=tablist] > [role=tab]:hover,[role=tablist] > [role=tab]:focus-visible){color:var(--ob-primary)!important}
.tool-calculator-shell form{width:100%;margin:0!important;border:0!important;border-radius:0!important;background:transparent!important;box-shadow:none!important}.tool-calculator-shell form h2:first-of-type
{margin:0!important;padding:1.5rem 2rem .35rem;color:var(--ob-text);font-size:1.15rem;font-weight:700;line-height:1.3}.tool-calculator-shell form h2:first-of-type+p
{margin:0!important;padding:0 2rem 1.25rem;border-bottom:1px solid var(--ob-border);color:var(--ob-text-secondary);line-height:1.55}.tool-calculator-shell .calculator-fields,.tool-calculator-shell form>.grid.gap-5
{width:100%!important;min-width:0;margin:0!important;padding:1.5rem 2rem!important}.tool-calculator-shell label
{display:block;margin-bottom:.45rem;color:var(--ob-text)!important;font-size:.8rem;font-weight:600}.tool-calculator-shell .calculator-fields>div>p
{margin:.4rem 0 0;color:var(--ob-text-secondary);font-size:.75rem;line-height:1.45}
.tool-calculator-shell .tool-option-checkbox{display:grid!important;grid-template-columns:1.25rem minmax(0,1fr);align-items:center;justify-content:initial!important;justify-self:start!important;width:100%!important;grid-column:1/-1;gap:.75rem;min-height:3rem;margin:0!important;padding:.65rem 1rem;border:1px solid var(--ob-border);border-radius:.75rem;color:var(--ob-text);text-align:left!important}
.tool-calculator-shell #salary-all-options{width:100%!important;margin:0!important;padding:1.5rem 2rem!important}
.tool-calculator-shell #salary-all-options>.grid{width:100%!important;justify-content:stretch!important;justify-items:start!important}
.tool-calculator-shell #salary-all-options .tool-option-checkbox{justify-self:stretch!important;align-self:stretch!important}
.tool-calculator-shell .tool-option-checkbox-input{width:1.25rem!important;height:1.25rem!important;min-width:1.25rem!important;min-height:1.25rem!important;margin:0!important;flex:0 0 1.25rem;accent-color:var(--ob-primary)}
.tool-calculator-shell .tool-option-checkbox>span{display:block;line-height:1.45}.tool-calculator-shell .calculator-submit-area
{display:block!important;text-align:initial!important}.tool-calculator-shell .calculator-submit-area>[role=alert]:not(.hidden)
{display:block!important;width:100%!important;margin:0 0 1rem!important;box-sizing:border-box}
.tool-calculator-shell .tool-control,.tool-calculator-shell input:not([type=checkbox]):not([type=radio]):not([type=hidden]),.tool-calculator-shell select,.tool-calculator-shell textarea{box-sizing:border-box;width:100%;min-width:0;min-height:3rem;padding:.75rem 1rem!important;border:1px solid var(--ob-border-input)!important;border-radius:.7rem!important;background:var(--ob-surface)!important;color:var(--ob-text)!important;box-shadow:none!important}
.tool-calculator-shell [data-electronics-mode^="color"] select:required:invalid{color:var(--ob-text-secondary)!important}
.tool-calculator-shell [data-electronics-mode^="color"] select:required:invalid option[value=""]{color:var(--ob-text-secondary)}
.tool-calculator-shell .tool-control:focus,.tool-calculator-shell input:not([type=checkbox]):not([type=radio]):focus,.tool-calculator-shell select:focus,.tool-calculator-shell textarea:focus{border-color:var(--ob-primary)!important;outline:0;box-shadow:0 0 0 3px color-mix(in srgb,var(--ob-primary) 16%,transparent)!important}.tool-calculator-shell .calculator-input-with-unit
{position:relative;width:100%;min-width:0}.tool-calculator-shell .calculator-input-with-unit>input.tool-control
{width:100%!important;min-width:0}.tool-calculator-shell .calculator-input-with-unit>span
{position:absolute!important;inset-block:0;right:1rem;display:flex;align-items:center;justify-content:center;min-height:0;padding:0!important;border:0!important;color:var(--ob-text-secondary);font-size:.8rem;pointer-events:none}.tool-calculator-shell .calculator-submit-area,.tool-calculator-shell form>div:has(>button[type=submit])
{width:100%;margin:0!important;padding:1.25rem 2rem!important;border:0!important;box-sizing:border-box}
.tool-calculator-shell button[type=submit],.tool-calculator-shell .tool-submit{width:100%!important;min-height:3.25rem;margin:0!important;border:0!important;border-radius:.7rem!important;background:var(--ob-primary)!important;color:#fff!important;font-weight:700;box-shadow:none!important}
.tool-calculator-shell button[type=submit]:hover{background:var(--ob-primary-hover)!important}.tool-calculator-shell .calculator-result,.tool-calculator-shell section[aria-live=polite]
{width:100%;margin:0!important;padding:1.5rem 2rem!important;border:0!important;border-radius:0;background:transparent;color:var(--ob-text)}


.tool-calculator-shell .calculator-result .calculator-result-heading{margin:0!important;padding:0!important;border:0!important;background:transparent!important}
.tool-calculator-shell .water-result .calculator-result-heading{margin:0 0 1.75rem!important}
.tool-calculator-shell .calculator-result .calculator-result-heading>p{margin:0;color:var(--ob-primary);font-size:.75rem;font-weight:700;letter-spacing:.14em;line-height:1.4;text-transform:uppercase}
.tool-calculator-shell .calculator-result .calculator-result-main{display:flex;align-items:baseline;gap:.65rem;margin-top:.65rem;padding:0!important;border:0!important;border-radius:0!important;background:transparent!important}
.tool-calculator-shell .calculator-result .calculator-result-main>p:first-child{margin:0;color:var(--ob-primary);font-size:2rem;font-weight:700;line-height:1.15}
.tool-calculator-shell .calculator-result .calculator-result-main>p:not(:first-child){margin:0;color:var(--ob-text-secondary);font-size:1rem;font-weight:600;line-height:1.4}
.tool-calculator-shell .tool-note{display:flex!important;align-items:flex-start;gap:.75rem;box-sizing:border-box;width:100%;margin:1.25rem 0 0!important;padding:.9rem 1rem!important;border:1px solid var(--ob-border)!important;border-radius:.75rem;background:var(--ob-surface);color:var(--ob-text-secondary);line-height:1.55;text-align:left}
.tool-calculator-shell .tool-note-icon{display:grid;flex:0 0 1.25rem;width:1.25rem;height:1.25rem;place-items:center;border-radius:999px;background:var(--ob-primary-light);color:var(--ob-primary);font-size:.75rem;font-weight:700;line-height:1}
.tool-calculator-shell .tool-note p{margin:0!important;color:inherit;font:inherit;line-height:inherit}
.tool-calculator-shell .virtual-breathalyzer-driving-warning{margin-bottom:1.25rem!important;border-color:#ef4444!important;background:transparent!important;color:var(--ob-text)!important}
.tool-calculator-shell .virtual-breathalyzer-driving-warning .tool-note-icon{border:1px solid #ef4444;background:transparent;color:#ef4444}
.tool-calculator-shell .virtual-breathalyzer-driving-warning-copy{min-width:0}
.tool-calculator-shell .virtual-breathalyzer-driving-warning-title{margin:0 0 .25rem!important;color:#ef4444!important;font-size:1.05rem!important;font-weight:700!important;line-height:1.4}
.tool-calculator-shell .virtual-breathalyzer-driving-warning-text{color:var(--ob-text)!important;font-size:.9rem!important;font-weight:400!important;line-height:1.5}
@media(max-width:639px){.tool-container{padding-inline:.75rem}.tool-intro-inner{padding-block:1.15rem 1rem}.tool-calculator-section{padding-block:.75rem 1.25rem}.tool-calculator-shell{border-radius:.7rem}.tool-calculator-shell form h2:first-of-type,.tool-calculator-shell form h2:first-of-type+p,.tool-calculator-shell .calculator-fields,.tool-calculator-shell form>.grid.gap-5,.tool-calculator-shell .calculator-submit-area,.tool-calculator-shell form>div:has(>button[type=submit]),.tool-calculator-shell .calculator-result,.tool-calculator-shell section[aria-live=polite]
{padding-left:1rem!important;padding-right:1rem!important}.tool-calculator-shell .calculator-result>.grid
{grid-template-columns:1fr;gap:1rem}.tool-calculator-shell [role=tab]{min-height:3.6rem;padding-inline:.35rem;font-size:.75rem}}
@media(max-width:767px){.tool-calculator-shell .calorie-result>.grid,.tool-calculator-shell .calorie-result .grid{gap:1.5rem!important}.tool-calculator-shell #bmi-result #result-bmi>.grid{grid-template-columns:1fr;gap:1.5rem}.tool-calculator-shell #bmi-result #result-bmi>.grid>div:nth-child(2){grid-template-columns:repeat(3,minmax(0,1fr));gap:.75rem}.tool-calculator-shell .bmi-interpretation-row{grid-template-columns:1fr 1.2fr 1fr;font-size:.68rem}.tool-calculator-shell .bmi-interpretation-row>*{padding:.55rem .5rem}}
@media(max-width:520px){.tool-calculator-shell #bmi-result #result-bmi>.grid>div:nth-child(2){grid-template-columns:1fr 1fr}.tool-calculator-shell #bmi-result #result-bmi>.grid>div:nth-child(2)>div:last-child{grid-column:1/-1}.tool-calculator-shell #bmi-result #result-bmi>.grid>div:first-child>div:nth-child(2)>div:last-child{font-size:.58rem}.tool-calculator-shell .bmi-interpretation-table{overflow-x:auto}.tool-calculator-shell .bmi-interpretation-row{min-width:28rem}}


/* =========================================================
 * KALKULATORY KALORYCZNE - WSPÓLNY WZORZEC WYNIKU
 * Każdy tryb ma własny HTML/JS. Te klasy opisują wyłącznie
 * wspólny wygląd wyników trzech narzędzi kalorycznych.
 * ========================================================= */

.tool-calculator-shell .calorie-fields{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:1.25rem 1.5rem;
}

.tool-calculator-shell .calorie-field-pal{
    grid-column:1/-1;
}

.tool-calculator-shell .calorie-result{
    padding:2rem!important;
}

.tool-calculator-shell .calorie-result .calculator-result-heading{
    display:grid;
    grid-template-columns:minmax(0,1fr) minmax(15rem,auto);
    grid-template-areas:
        "label label"
        "main main";
    align-items:end;
    column-gap:2rem;
    row-gap:.45rem;
    margin:0 0 1.75rem!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
}

/* Wspólny rytm wyniku: mała etykieta, duża wartość, krótki opis. */
.tool-calculator-shell .calorie-result .calculator-result-heading>p{
    grid-area:label;
    margin:0!important;
    padding:0!important;
    border:0!important;
    color:var(--ob-primary)!important;
    font-size:.75rem!important;
    font-weight:700!important;
    letter-spacing:.14em!important;
    line-height:1.3!important;
    text-transform:uppercase!important;
}

.tool-calculator-shell .calorie-result .calculator-result-main{
    grid-area:main;
    display:flex;
    align-items:baseline;
    gap:.7rem;
    min-width:0;
    margin:0!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
}

.tool-calculator-shell .calorie-result .calculator-result-main>p:first-child{
    color:var(--ob-primary)!important;
    font-size:2.35rem!important;
    font-weight:700!important;
    line-height:1.05!important;
    letter-spacing:-.025em;
}

.tool-calculator-shell .calorie-result .calculator-result-main>p:last-child{
    color:var(--ob-text-secondary)!important;
    font-size:.95rem!important;
    font-weight:600!important;
    line-height:1.3!important;
}

.tool-calculator-shell .calorie-result-grid{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:1.5rem;
}

.tool-calculator-shell .calorie-result-grid-3{
    grid-template-columns:repeat(2,minmax(0,1fr));
}
.tool-calculator-shell .calculator-result-grid-single{
    grid-template-columns:minmax(0,1fr)!important;
}

.tool-calculator-shell .calculator-result.calorie-result:not(#bmi-result) .calorie-result-card:not(.calculator-result-card-primary):not(.calorie-result-card-primary){
    display:block!important;
    min-width:0;
    margin:0!important;
    padding:1.15rem 1.25rem!important;
    border:1px solid var(--ob-border)!important;
    border-radius:.8rem!important;
    background:var(--ob-surface-soft)!important;
    box-shadow:none!important;
}

.tool-calculator-shell .calculator-result.calorie-result:not(#bmi-result) .calorie-result-card-primary{
    border:2px solid var(--ob-primary)!important;
    background:var(--ob-surface)!important;
}
.tool-calculator-shell .calculator-result.calorie-result:not(#bmi-result) .calorie-result-card-primary .calorie-card-label{
    color:var(--ob-primary);
}
.tool-calculator-shell .calculator-result.calorie-result:not(#bmi-result) .calorie-result-card-primary .calorie-card-value{
    color:var(--ob-primary);
}
.tool-calculator-shell .calculator-result.calorie-result:not(#bmi-result) .virtual-breathalyzer-zero-card{
    border:1px solid #22c55e!important;
}
.tool-calculator-shell .calculator-result.calorie-result:not(#bmi-result) .calorie-result-card.hidden{
    display:none!important;
}

.tool-calculator-shell .calculator-result :is(.calculator-result-card-primary,.calorie-result-card-primary),
.tool-calculator-shell .calculator-result > .calculator-result-card:only-of-type{
    border:2px solid var(--ob-primary)!important;
    background:var(--ob-surface)!important;
}
.tool-calculator-shell .calculator-result :is(.calculator-result-card-primary,.calorie-result-card-primary) :is(.calorie-card-label,.calculator-card-label,.calorie-card-value,.calculator-card-value),
.tool-calculator-shell .calculator-result > .calculator-result-card:only-of-type :is(.calorie-card-label,.calculator-card-label,.calorie-card-value,.calculator-card-value){
    color:var(--ob-primary)!important;
}
.tool-calculator-shell :is(.calculator-result-grid,.calorie-result-grid):has(> :last-child:nth-child(odd)) > :is(.calculator-result-card-primary,.calorie-result-card-primary){
    grid-column:1/-1;
}
.tool-calculator-shell .calculator-result:not(.hidden):has(> :is(.calculator-result-card-primary,.calorie-result-card-primary)):has(> :is(.calculator-result-grid,.calorie-result-grid)){
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:1rem;
}
.tool-calculator-shell .calculator-result:not(.hidden):has(> :is(.calculator-result-card-primary,.calorie-result-card-primary)) > :is(.calculator-result-heading,.tool-note,.calorie-result-note){
    grid-column:1/-1;
}
.tool-calculator-shell .calculator-result:not(.hidden):has(> :is(.calculator-result-card-primary,.calorie-result-card-primary)) > .calculator-result-heading{
    margin:0 0 .25rem!important;
}
.tool-calculator-shell .calculator-result:not(.hidden):has(> :is(.calculator-result-card-primary,.calorie-result-card-primary)) > :is(.calculator-result-grid,.calorie-result-grid){
    display:contents;
}
/* The primary card counts toward the total: an odd total means an even number of detail cards. */
.tool-calculator-shell .calculator-result:has(> :is(.calculator-result-card-primary,.calorie-result-card-primary)):has(> :is(.calculator-result-grid,.calorie-result-grid):has(> :last-child:nth-child(even))) > :is(.calculator-result-card-primary,.calorie-result-card-primary){
    grid-column:1/-1;
}
.tool-calculator-shell .calculator-result.calculator-result-odd-count > :is(.calculator-result-card-primary,.calorie-result-card-primary){
    grid-column:1/-1!important;
}
.tool-calculator-shell .calculator-result.calculator-result-even-count > :is(.calculator-result-card-primary,.calorie-result-card-primary){
    grid-column:auto!important;
}

.tool-calculator-shell .calorie-card-label{
    margin:0;
    color:var(--ob-text-secondary);
    font-size:.72rem;
    font-weight:600;
    line-height:1.4;
}

.tool-calculator-shell .calorie-card-value{
    display:flex;
    align-items:baseline;
    flex-wrap:wrap;
    gap:.35rem;
    margin:.3rem 0 0;
    color:var(--ob-text);
    font-size:1.65rem;
    font-weight:700;
    line-height:1.15;
}

.tool-calculator-shell .calorie-card-unit{
    color:var(--ob-text-secondary);
    font-size:.8rem;
    font-weight:600;
}

.tool-calculator-shell .calorie-card-description{
    margin:.35rem 0 0;
    color:var(--ob-text-secondary);
    font-size:.75rem;
    line-height:1.45;
}

.tool-calculator-shell .calorie-result-note{
    display:flex;
    align-items:flex-start;
    gap:.75rem;
    width:100%;
    box-sizing:border-box;
    margin:1.5rem 0 0!important;
    padding:.9rem 1rem!important;
    border:1px solid var(--ob-border)!important;
    border-radius:.75rem!important;
    background:var(--ob-surface)!important;
    color:var(--ob-text-secondary);
}

.tool-calculator-shell .calorie-result-note-icon{
    display:grid;
    flex:0 0 1.25rem;
    width:1.25rem;
    height:1.25rem;
    place-items:center;
    border-radius:999px;
    background:var(--ob-primary-light);
    color:var(--ob-primary);
    font-size:.75rem;
    font-weight:700;
    line-height:1;
}

.tool-calculator-shell .calorie-result-note p{
    margin:0!important;
    color:inherit;
    font-size:.8rem;
    line-height:1.55;
}

.tool-calculator-shell .bmi-form-fields{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:1.25rem 1.5rem;
}

@media(max-width:767px){
    .tool-calculator-shell .calorie-fields,
    .tool-calculator-shell .bmi-form-fields{
        grid-template-columns:1fr;
    }

    .tool-calculator-shell .calorie-field-pal{
        grid-column:auto;
    }

    .tool-calculator-shell .calorie-result{
        padding:1.5rem!important;
    }

    .tool-calculator-shell .calorie-result .calculator-result-heading{
        grid-template-columns:1fr;
        grid-template-areas:
            "label"
            "main";
        row-gap:.45rem;
    }


    .tool-calculator-shell .calorie-result-grid,
    .tool-calculator-shell .calorie-result-grid-3{
        grid-template-columns:1fr;
        gap:1.25rem;
    }
}

@media(max-width:520px){
    .tool-calculator-shell .calorie-result{
        padding:1rem!important;
    }

    .tool-calculator-shell .calorie-result .calculator-result-main>span:first-child{
        font-size:1.8rem;
    }
}


.tool-calculator-shell .calculator-form-header h2,
.tool-calculator-shell .calculator-form > h2{
    margin:0;
}

.tool-calculator-shell .calculator-form-header p,
.tool-calculator-shell .calculator-form > h2 + p{
    margin:0;
}

.tool-calculator-shell .calculator-fields label:has(> input[type="checkbox"]),
.tool-calculator-shell .tool-option-checkbox{
    display:grid;
    grid-template-columns:1.25rem minmax(0,1fr);
    align-items:start;
    gap:.75rem;
    width:100%;
    min-height:3rem;
    margin:0;
    padding:.65rem 1rem;
    border:1px solid var(--ob-border);
    border-radius:.75rem;
    color:var(--ob-text);
    text-align:left;
}

.tool-calculator-shell .date-time-option-heading{
    margin:0 0 .45rem;
    color:var(--ob-text);
    font-size:.8rem;
    font-weight:600;
}

.tool-calculator-shell .calculator-fields label:has(> input[type="checkbox"]) > input[type="checkbox"],
.tool-calculator-shell .tool-option-checkbox > input[type="checkbox"]{
    width:1.25rem;
    height:1.25rem;
    margin:.1rem 0 0;
    accent-color:var(--ob-primary);
}

.tool-calculator-shell .calculator-fields label:has(> input[type="checkbox"]) > span,
.tool-calculator-shell .tool-option-checkbox > span{
    display:block;
    line-height:1.45;
}

.tool-calculator-shell .calculator-result > div:has(> div):not(.bmi-scale):not(.bmi-interpretation):not(.tool-note):not(.calorie-result-note):not(.calculator-result-heading):not(.heart-zones){
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:1rem;
    margin:1.25rem 0 0;
}

.tool-calculator-shell .calculator-result > div:has(> div):not(.bmi-scale):not(.bmi-interpretation):not(.tool-note):not(.calorie-result-note):not(.calculator-result-heading):not(.heart-zones) > div{
    min-width:0;
    margin:0;
    padding:1.15rem 1.25rem;
    border:1px solid var(--ob-border);
    border-radius:.8rem;
    background:var(--ob-surface-soft);
}

@media(max-width:767px){
    .tool-calculator-shell .calculator-result > div:has(> div){
        grid-template-columns:1fr;
        gap:.85rem;
    }
}

/* =========================================================
 * NOWY SYSTEM NARZĘDZI - komponenty kanoniczne
 * Docelowa warstwa dla zmigrowanych kalkulatorów.
 * ========================================================= */

.tool-calculator-shell .calculator-fields-2{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:1.25rem 1.5rem;
    width:100%;
    margin:0;
    padding:1.5rem 2rem;
}
.tool-calculator-shell .teacher-supplementary-leave-fields>div>label{display:block}
@media(min-width:768px){.tool-calculator-shell .teacher-supplementary-leave-fields>div>label{min-height:2.8em}}

.tool-calculator-shell .thyroid-groups{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1rem;padding:1.5rem 2rem}
.tool-calculator-shell .thyroid-group{min-width:0;margin:0;padding:1rem;border:1px solid var(--ob-border);border-radius:.8rem;background:var(--ob-surface-soft)}
.tool-calculator-shell .thyroid-group legend{padding:0 .35rem;color:var(--ob-text);font-size:1rem;font-weight:700}
.tool-calculator-shell .thyroid-fields{display:grid;gap:1rem}
.tool-calculator-shell .thyroid-status{text-transform:capitalize}
@media(max-width:900px){.tool-calculator-shell .thyroid-groups{grid-template-columns:1fr}}

.tool-calculator-shell .calculator-field-full{
    grid-column:1 / -1;
}

.tool-calculator-shell .calculator-fields-2>div>p{
    margin:.4rem 0 0;
    color:var(--ob-text-secondary);
    font-size:.75rem;
    line-height:1.45;
}

/* WHR/WHtR: use the same compact result heading and bordered cards as the health-tool standard. */
.tool-calculator-shell .body-index-result{
    padding:1.5rem 2rem!important;
}
.tool-calculator-shell .body-index-result .calculator-result-heading{
    display:block!important;
    margin:0 0 1.25rem!important;
    padding:0!important;
    border:0!important;
    border-radius:0!important;
    background:transparent!important;
}
.tool-calculator-shell .body-index-result .calculator-result-heading>p{
    margin:0!important;
    color:var(--ob-primary)!important;
    font-size:.75rem!important;
    font-weight:700!important;
    letter-spacing:.14em!important;
    line-height:1.4!important;
    text-transform:uppercase!important;
}
.tool-calculator-shell .body-index-result .body-index-result-grid .calculator-result-card{
    display:flex!important;
    flex-direction:column;
    justify-content:flex-start;
    min-width:0;
    margin:0!important;
    padding:1.15rem 1.25rem!important;
    border:1px solid var(--ob-border)!important;
    border-radius:1rem!important;
    background:var(--ob-surface-soft)!important;
    box-shadow:none!important;
}
.tool-calculator-shell .body-index-result .body-index-result-grid .body-index-result-card-primary{
    border:2px solid var(--ob-primary)!important;
    background:var(--ob-surface)!important;
}
.tool-calculator-shell .body-index-result .body-index-result-grid .calculator-card-label{
    margin:0!important;
    color:var(--ob-text-secondary)!important;
    font-size:.8rem!important;
    font-weight:600!important;
    line-height:1.4!important;
}
.tool-calculator-shell .body-index-result .body-index-result-grid .body-index-result-card-primary .calculator-card-label{
    color:var(--ob-primary)!important;
}
.tool-calculator-shell .body-index-result .body-index-result-grid .body-index-result-value{
    margin:.35rem 0 0!important;
    color:var(--ob-primary)!important;
    font-size:2rem!important;
    font-weight:700!important;
    line-height:1.2!important;
}
.tool-calculator-shell .body-index-result .body-index-result-grid .body-index-result-category{
    margin:.35rem 0 0!important;
    color:var(--ob-text)!important;
    font-size:1rem!important;
    font-weight:600!important;
    line-height:1.45!important;
    overflow-wrap:anywhere;
}
.tool-calculator-shell .body-index-result .body-index-result-grid .body-index-result-threshold{
    margin:.65rem 0 0!important;
    color:var(--ob-text-secondary)!important;
    font-size:.875rem!important;
    font-weight:400!important;
    line-height:1.5!important;
    overflow-wrap:anywhere;
}
@media(max-width:600px){
    .tool-calculator-shell .body-index-result{padding:1.25rem 1rem!important}
    .tool-calculator-shell .body-index-result .body-index-result-grid{grid-template-columns:minmax(0,1fr)!important}
}
.tool-calculator-shell .body-index-result-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
    align-items:stretch;
    gap:1rem;
}
.tool-calculator-shell .body-index-result-grid .calculator-result-card{
    display:flex;
    flex-direction:column;
    justify-content:flex-start;
    min-width:0;
    padding:1.15rem 1.25rem;
    border:1px solid var(--ob-border);
    border-radius:1rem;
    background:var(--ob-surface-soft);
}
.tool-calculator-shell .body-index-result-grid .body-index-result-card-primary{
    border:2px solid var(--ob-primary);
    background:var(--ob-surface);
}
.tool-calculator-shell .body-index-result-grid .body-index-result-card-primary .calculator-card-label{
    color:var(--ob-primary);
}
.tool-calculator-shell .body-index-result-grid .body-index-result-value{
    margin:.35rem 0 0;
    color:var(--ob-primary);
    font-size:2rem;
    font-weight:700;
    line-height:1.2;
}
.tool-calculator-shell .body-index-result-grid .body-index-result-category{
    margin:.35rem 0 0;
    color:var(--ob-text);
    font-size:1rem;
    font-weight:600;
    line-height:1.45;
    overflow-wrap:anywhere;
}
.tool-calculator-shell .body-index-result-grid .body-index-result-threshold{
    margin:.65rem 0 0;
    color:var(--ob-text-secondary);
    font-size:.875rem;
    line-height:1.5;
    overflow-wrap:anywhere;
}
@media(max-width:600px){
    .tool-calculator-shell .body-index-result-grid{
        grid-template-columns:minmax(0,1fr);
    }
}

.tool-calculator-shell .calculator-result-grid{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:1rem;
    margin:1.25rem 0 0;
}

.tool-calculator-shell .calculator-result-grid-3{
    grid-template-columns:repeat(2,minmax(0,1fr));
}
.tool-calculator-shell #trip-cost-breakdown-heading{margin-top:1.25rem!important}

/* Keep the highlighted result first in every calculator result grid. */
.tool-calculator-shell :is(.calculator-result,.calorie-result,.body-index-result) > .calculator-result-heading{
    order:-2;
}
.tool-calculator-shell :is(.calculator-result-grid,.calorie-result-grid,.body-index-result-grid) > :is(.calculator-result-card-primary,.calorie-result-card-primary,.body-index-result-card-primary,.water-result-primary,.heart-result-primary){
    order:-1;
}
.tool-calculator-shell :is(.calculator-result,.calorie-result):has(> :is(.calculator-result-card-primary,.calorie-result-card-primary)) > :is(.calculator-result-card-primary,.calorie-result-card-primary){
    order:-1;
}

.tool-calculator-shell .calculator-result-card{
    min-width:0;
    margin:0;
    padding:1.15rem 1.25rem;
    border:1px solid var(--ob-border);
    border-radius:.8rem;
    background:var(--ob-surface-soft);
}

.tool-calculator-shell .calculator-card-label{
    margin:0;
    color:var(--ob-text-secondary);
    font-size:.78rem;
    line-height:1.4;
}

.tool-calculator-shell .calculator-card-value{
    margin:.3rem 0 0;
    color:var(--ob-text);
    font-size:1.5rem;
    font-weight:700;
    line-height:1.2;
    overflow-wrap:anywhere;
}
.tool-calculator-shell #date-time-main-value.date-time-range-value{
    display:grid;
    gap:.4rem;
    font-size:1.35rem;
    line-height:1.35;
    overflow-wrap:normal;
}
.tool-calculator-shell .date-time-range-item{
    display:flex;
    flex-wrap:wrap;
    align-items:baseline;
    column-gap:.4rem;
    row-gap:.05rem;
    min-width:0;
}
.tool-calculator-shell .date-time-range-item time{white-space:nowrap}
.tool-calculator-shell .date-time-range-item-compact{flex-wrap:nowrap}
.tool-calculator-shell .date-time-range-separator{color:var(--ob-text-secondary);font-size:.9em}
.tool-calculator-shell #date-time-secondary-value.date-time-milestone-list{
    display:grid;
    gap:.55rem;
    margin:.55rem 0 0;
    font-size:.95rem;
    font-weight:600;
    line-height:1.35;
}
.tool-calculator-shell .date-time-milestone-item{
    display:flex;
    align-items:baseline;
    justify-content:space-between;
    gap:.6rem;
    padding-bottom:.45rem;
    border-bottom:1px solid var(--ob-border);
}
.tool-calculator-shell .date-time-milestone-item:last-child{padding-bottom:0;border-bottom:0}
.tool-calculator-shell .date-time-milestone-item>span{color:var(--ob-text-secondary)}
.tool-calculator-shell .date-time-milestone-item time{color:var(--ob-text);text-align:right;white-space:nowrap}
.tool-calculator-shell .calculator-result-card-primary .calculator-card-value{
    color:var(--ob-primary);
}
.tool-calculator-shell .calculator-result-card:is(.calculator-result-card-primary,.calorie-result-card-primary){
    border:2px solid var(--ob-primary)!important;
    background:var(--ob-surface)!important;
}
.tool-calculator-shell .calculator-result-card:is(.calculator-result-card-primary,.calorie-result-card-primary) :is(.calorie-card-label,.calculator-card-label,.calorie-card-value,.calculator-card-value){
    color:var(--ob-primary)!important;
}
.tool-calculator-shell .calculator-card-description{
    margin:.45rem 0 0;
    color:var(--ob-text-secondary);
    font-size:.85rem;
    line-height:1.5;
    overflow-wrap:anywhere;
}

.tool-calculator-shell .sleep-windows-card{min-width:0}
.tool-calculator-shell .sleep-windows-list{display:grid;gap:.55rem;margin:.75rem 0 0;padding:0;list-style:none}
.tool-calculator-shell .sleep-windows-list li{display:flex;align-items:center;justify-content:space-between;gap:.75rem;padding:.55rem .7rem;border:1px solid color-mix(in srgb,var(--ob-primary) 35%,var(--ob-border));border-radius:.55rem;background:color-mix(in srgb,var(--ob-primary) 7%,var(--ob-surface))}
.tool-calculator-shell .sleep-window-cycle{color:var(--ob-text-secondary);font-size:.76rem;font-weight:600}
.tool-calculator-shell .sleep-window-time{color:var(--ob-primary);font-size:1.1rem;font-weight:750;line-height:1.2;white-space:nowrap}
.tool-calculator-shell .calculator-result-subheading{
    margin:1.5rem 0 .75rem;
}

.tool-calculator-shell .calculator-result-subheading h3{
    margin:0;
    color:var(--ob-text);
    font-size:1rem;
    font-weight:700;
    line-height:1.35;
}

.tool-calculator-shell .calculator-result-subheading p{
    margin:.25rem 0 0;
    color:var(--ob-text-secondary);
    font-size:.8rem;
    line-height:1.45;
}

.tool-calculator-shell .calculator-result-detail{
    margin:1rem 0 0;
    color:var(--ob-text-secondary);
    font-size:.85rem;
    line-height:1.55;
}

/* Zapotrzebowanie na wodę - główny wynik zgodny z kartami wyników narzędzi zdrowotnych. */
.tool-calculator-shell .water-result .water-result-primary{
    display:block;
    margin:0 0 1rem;
    padding:1.15rem 1.25rem;
    border:2px solid var(--ob-primary);
    border-radius:.8rem;
    background:var(--ob-surface);
}
.tool-calculator-shell .water-result .water-result-primary .calculator-card-label{
    color:var(--ob-primary);
    font-size:.72rem;
    font-weight:600;
}
.tool-calculator-shell .water-result .water-result-primary .calculator-card-value{
    display:flex;
    align-items:baseline;
    flex-wrap:wrap;
    gap:.35rem;
    margin:.3rem 0 0;
    color:var(--ob-primary);
    font-size:1.65rem;
    font-weight:700;
    line-height:1.15;
}
.tool-calculator-shell .water-result .water-result-primary .calculator-card-value span{
    color:var(--ob-text-secondary);
    font-size:.8rem;
    font-weight:600;
}
.tool-calculator-shell .water-result .water-result-primary .calculator-card-value #water-value{
    color:var(--ob-primary);
    font-size:inherit;
    font-weight:inherit;
}
.tool-calculator-shell .water-result .water-result-primary .calculator-card-description{
    margin:.3rem 0 0;
    color:var(--ob-text-secondary);
    font-size:.8rem;
    line-height:1.5;
}

/* Kalkulator tetna - karty wyniku i tabela interpretacji */
.tool-calculator-shell .heart-result .calculator-result-heading{margin:0 0 1.25rem!important}
.tool-calculator-shell .heart-result .calculator-card-value{color:var(--ob-text)}
.tool-calculator-shell .heart-result .heart-result-primary{
    border:2px solid var(--ob-primary);
    background:var(--ob-surface);
}
.tool-calculator-shell .heart-result .heart-result-primary .calculator-card-label{color:var(--ob-primary)}
.tool-calculator-shell .heart-result .heart-zones{
    display:block;
    margin:1.25rem 0 0;
    padding:1.15rem 1.25rem;
    border:1px solid var(--ob-border);
    border-radius:.8rem;
    background:var(--ob-surface-soft);
}
.tool-calculator-shell .heart-result .heart-zones .calculator-result-subheading{margin:0 0 .85rem}
.tool-calculator-shell .heart-result .heart-zone-table-wrap{
    border:1px solid var(--ob-border);
    border-radius:.7rem;
    background:var(--ob-surface);
}
.tool-calculator-shell .heart-result .heart-zone-table tbody td:last-child{color:var(--ob-text)}
.tool-calculator-shell .heart-zone-table-wrap{
    width:100%;
    overflow:hidden;
    border:1px solid var(--ob-border);
    border-radius:.8rem;
    background:var(--ob-surface);
}
.tool-calculator-shell .heart-zone-table{
    width:100%;
    border-collapse:collapse;
    table-layout:fixed;
    color:var(--ob-text);
    font-size:.875rem;
}
.tool-calculator-shell .heart-zone-table th,
.tool-calculator-shell .heart-zone-table td{
    padding:.8rem .9rem;
    border-bottom:1px solid var(--ob-border);
    text-align:left;
    vertical-align:top;
    line-height:1.45;
    overflow-wrap:anywhere;
}
.tool-calculator-shell .heart-zone-table thead th{
    background:var(--ob-surface-soft);
    color:var(--ob-text-secondary);
    font-size:.75rem;
    font-weight:700;
}
.tool-calculator-shell .heart-zone-table tbody th{font-weight:700}
.tool-calculator-shell .heart-zone-table tbody td:last-child{color:var(--ob-primary);font-weight:700;white-space:nowrap}
.tool-calculator-shell .heart-zone-table tr:last-child th,
.tool-calculator-shell .heart-zone-table tr:last-child td{border-bottom:0}

@media(max-width:767px){
    .tool-calculator-shell .calculator-fields-2,
    .tool-calculator-shell .calculator-result-grid,
    .tool-calculator-shell .calculator-result-grid-3{
        grid-template-columns:1fr;
    }

    .tool-calculator-shell .calculator-fields-2{
        padding:1.5rem 1.25rem;
    }

    .tool-calculator-shell .calculator-result-grid{
        gap:.85rem;
    }
    .tool-calculator-shell .calculator-result:not(.hidden):has(> :is(.calculator-result-card-primary,.calorie-result-card-primary)):has(> :is(.calculator-result-grid,.calorie-result-grid)){
        grid-template-columns:1fr;
    }

    .tool-calculator-shell .heart-result .heart-zones{padding:.9rem .75rem}
    .tool-calculator-shell .heart-zone-table{font-size:.75rem}
    .tool-calculator-shell .heart-zone-table th,
    .tool-calculator-shell .heart-zone-table td{padding:.65rem .45rem;font-size:.75rem}
    .tool-calculator-shell .heart-zone-table thead th{font-size:.66rem}
    .tool-calculator-shell .heart-zone-table tbody td:last-child{white-space:normal}
}


/* Strefy tętna: dokładnie ten sam układ tabeli interpretacji co BMI */
.tool-calculator-shell .heart-result .heart-zones{
    display:block;
    margin:1.25rem 0 0;
    padding:0;
    border:0;
    border-radius:0;
    background:transparent;
}
.tool-calculator-shell .heart-result .bmi-interpretation{
    margin-top:0;
}
.tool-calculator-shell .heart-result .heart-interpretation-table{
    overflow:hidden;
    border:1px solid var(--ob-border);
    border-radius:.7rem;
}
.tool-calculator-shell .heart-result .heart-interpretation-table .heart-zone-row:nth-child(2){background:color-mix(in srgb,#60a5fa 11%,var(--ob-surface));box-shadow:inset 4px 0 #60a5fa}
.tool-calculator-shell .heart-result .heart-interpretation-table .heart-zone-row:nth-child(3){background:color-mix(in srgb,#4ade80 11%,var(--ob-surface));box-shadow:inset 4px 0 #4ade80}
.tool-calculator-shell .heart-result .heart-interpretation-table .heart-zone-row:nth-child(4){background:color-mix(in srgb,#facc15 11%,var(--ob-surface));box-shadow:inset 4px 0 #facc15}
.tool-calculator-shell .heart-result .heart-interpretation-table .heart-zone-row:nth-child(5){background:color-mix(in srgb,#fb923c 11%,var(--ob-surface));box-shadow:inset 4px 0 #fb923c}
.tool-calculator-shell .heart-result .heart-interpretation-table .heart-zone-row:nth-child(6){background:color-mix(in srgb,#a78bfa 11%,var(--ob-surface));box-shadow:inset 4px 0 #a78bfa}
.tool-calculator-shell .heart-result .heart-zone-row:nth-child(2) strong:first-child{color:#60a5fa}
.tool-calculator-shell .heart-result .heart-zone-row:nth-child(3) strong:first-child{color:#4ade80}
.tool-calculator-shell .heart-result .heart-zone-row:nth-child(4) strong:first-child{color:#facc15}
.tool-calculator-shell .heart-result .heart-zone-row:nth-child(5) strong:first-child{color:#fb923c}
.tool-calculator-shell .heart-result .heart-zone-row:nth-child(6) strong:first-child{color:#a78bfa}
.tool-calculator-shell .heart-result .heart-zone-row strong:last-child{color:var(--ob-text);font-weight:700}
@media(max-width:520px){
    .tool-calculator-shell .heart-result .heart-interpretation-table .bmi-interpretation-header{display:none}
    .tool-calculator-shell .heart-result .heart-interpretation-table .heart-zone-row{
        grid-template-columns:1fr;
        gap:.15rem;
        padding:.65rem .75rem;
    }
    .tool-calculator-shell .heart-result .heart-interpretation-table .heart-zone-row>*{padding:0}
}

/* BMI - kanoniczny wariant wyniku */
.tool-calculator-shell .bmi-category-value.bmi-category-under{color:#60a5fa}
.tool-calculator-shell .bmi-category-value.bmi-category-normal{color:#4ade80}
.tool-calculator-shell .bmi-category-value.bmi-category-over{color:#facc15}
.tool-calculator-shell .bmi-category-value.bmi-category-obesity-1{color:#fb923c}
.tool-calculator-shell .bmi-category-value.bmi-category-obesity-2{color:#f87171}
.tool-calculator-shell .bmi-category-value.bmi-category-obesity-3{color:#a78bfa}

.tool-calculator-shell .bmi-scale{
    position:relative;
    width:calc(100% - 2rem);
    max-width:27rem;
    margin:1.5rem auto 0;
    padding-top:1.35rem;
}

.tool-calculator-shell .bmi-scale-bar{
    position:relative;
    display:flex;
    width:100%;
    height:1.75rem;
    overflow:hidden;
    border-radius:.65rem;
}

.tool-calculator-shell .bmi-scale-segment{
    display:block;
    height:100%;
}

.tool-calculator-shell .bmi-scale-segment:first-child{
    border-radius:.65rem 0 0 .65rem;
}

.tool-calculator-shell .bmi-scale-obesity-3{
    border-radius:0 .65rem .65rem 0;
}

.tool-calculator-shell .bmi-scale-under{width:21.25%;background:#60a5fa}
.tool-calculator-shell .bmi-scale-normal{width:16.25%;background:#4ade80}
.tool-calculator-shell .bmi-scale-over{width:12.5%;background:#facc15}
.tool-calculator-shell .bmi-scale-obesity-1{width:12.5%;background:#fb923c}
.tool-calculator-shell .bmi-scale-obesity-2{width:12.5%;background:#f87171}
.tool-calculator-shell .bmi-scale-obesity-3{width:25%;background:#a78bfa}

.tool-calculator-shell .bmi-scale-marker{
    position:absolute;
    top:50%;
    left:0;
    display:block;
    width:.95rem;
    height:.95rem;
    transform:translate(-50%,-50%);
    border:3px solid var(--ob-surface);
    border-radius:50%;
    background:var(--ob-primary);
    box-shadow:0 0 0 2px var(--ob-primary);
    z-index:3;
    pointer-events:none;
}
.tool-calculator-shell .bmi-scale-marker-label{position:absolute;top:.05rem;left:0;transform:translateX(-50%);color:var(--ob-primary);font-size:.8rem;font-weight:700;line-height:1.2;white-space:nowrap}

.tool-calculator-shell .bmi-scale-labels{
    display:grid;
    grid-template-columns:repeat(6,minmax(0,1fr));
    gap:.2rem;
    margin-top:.55rem;
    color:var(--ob-text-secondary);
    font-size:.6rem;
    line-height:1.2;
    text-align:center;
}
.tool-calculator-shell .bmi-scale-labels>span{
    min-width:0;
}
.tool-calculator-shell .bmi-scale-labels strong{
    display:block;
    margin-bottom:.1rem;
    color:var(--ob-text);
    font-size:inherit;
    font-weight:600;
    white-space:nowrap;
}



/* Skala BMI: większa i czytelniejsza na desktopie; układ mobilny pozostaje bez zmian. */
@media(min-width:768px){
    .tool-calculator-shell .bmi-scale{
        width:calc(100% - 2rem);
        max-width:42rem;
        margin-top:2rem;
        padding-top:1.75rem;
    }

    .tool-calculator-shell .bmi-scale-bar{
        height:2.5rem;
        border-radius:.85rem;
    }

    .tool-calculator-shell .bmi-scale-segment:first-child{
        border-radius:.85rem 0 0 .85rem;
    }

    .tool-calculator-shell .bmi-scale-obesity-3{
        border-radius:0 .85rem .85rem 0;
    }

    .tool-calculator-shell .bmi-scale-labels{
        gap:.45rem;
        margin-top:.75rem;
        font-size:.82rem;
        line-height:1.3;
    }

    .tool-calculator-shell .bmi-scale-labels strong{
        margin-bottom:.2rem;
        font-size:.82rem;
        white-space:normal;
    }

    .tool-calculator-shell .bmi-scale-marker{width:1rem;height:1rem}
}

.tool-calculator-shell .bmi-interpretation{
    margin-top:1.5rem;
    padding-top:0;
    border-top:0;
}

.tool-calculator-shell .bmi-interpretation-heading h3{
    margin:0;
    color:var(--ob-text);
    font-size:1rem;
    font-weight:700;
}

.tool-calculator-shell .bmi-interpretation-heading p{
    margin:.25rem 0 .85rem;
    color:var(--ob-text-secondary);
    font-size:.75rem;
}

.tool-calculator-shell .bmi-interpretation-table{
    overflow:hidden;
    border:1px solid var(--ob-border);
    border-radius:.7rem;
}

.tool-calculator-shell .bmi-interpretation-row{
    display:grid;
    grid-template-columns:minmax(7rem,.9fr) minmax(9rem,1.35fr) minmax(7rem,.85fr);
    align-items:center;
    min-height:2.6rem;
    border-top:1px solid var(--ob-border);
    color:var(--ob-text-secondary);
    font-size:.75rem;
}

.tool-calculator-shell .bmi-interpretation-row:first-child{
    border-top:0;
}

.tool-calculator-shell .bmi-interpretation-row>*{
    min-width:0;
    padding:.65rem .8rem;
}

.tool-calculator-shell .bmi-interpretation-row strong{
    color:var(--ob-text);
    font-weight:600;
}

.tool-calculator-shell .bmi-interpretation-header{
    background:var(--ob-surface-soft);
    color:var(--ob-text);
    font-size:.7rem;
    font-weight:700;
}

/* Kolory wierszy BMI odpowiadają skali i tabeli stref tętna. */
.tool-calculator-shell .bmi-interpretation-row.bmi-category-under{
    background:color-mix(in srgb,#60a5fa 9%,var(--ob-surface));
}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-normal{
    background:color-mix(in srgb,#4ade80 9%,var(--ob-surface));
}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-over{
    background:color-mix(in srgb,#facc15 9%,var(--ob-surface));
}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-obesity-1{
    background:color-mix(in srgb,#fb923c 9%,var(--ob-surface));
}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-obesity-2{
    background:color-mix(in srgb,#ef4444 9%,var(--ob-surface));
}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-obesity-3{
    background:color-mix(in srgb,#8b5cf6 9%,var(--ob-surface));
}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-under strong{color:#60a5fa}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-normal strong{color:#4ade80}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-over strong{color:#facc15}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-obesity-1 strong{color:#fb923c}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-obesity-2 strong{color:#ef4444}
.tool-calculator-shell .bmi-interpretation-row.bmi-category-obesity-3 strong{color:#8b5cf6}
.tool-calculator-shell .bmi-interpretation-row.is-current{position:relative;z-index:1;outline:2px solid var(--ob-primary);outline-offset:-2px;background:color-mix(in srgb,var(--ob-primary) 12%,var(--ob-surface))!important;font-weight:700}
.tool-calculator-shell .bmi-interpretation-row.is-current strong{font-weight:800}

.tool-calculator-shell .child-bmi-result-grid{margin-top:1rem}
.tool-calculator-shell .child-bmi-interpretation{margin-top:1.75rem}
.tool-calculator-shell .child-bmi-section-heading h3{margin:0;color:var(--ob-text);font-size:1rem;font-weight:700}
.tool-calculator-shell .child-bmi-section-heading p{margin:.25rem 0 .9rem;color:var(--ob-text-secondary);font-size:.78rem}
.tool-calculator-shell .child-bmi-scale{position:relative;padding:2rem .35rem .15rem}
.tool-calculator-shell .child-bmi-scale-track{display:flex;overflow:hidden;height:1.75rem;border-radius:.85rem;background:var(--ob-surface-soft)}
.tool-calculator-shell .child-bmi-segment{display:block;flex:1;min-width:0}
.tool-calculator-shell .child-bmi-severe{display:none;background:#60a5fa}
.tool-calculator-shell .child-bmi-low{background:#60a5fa}
.tool-calculator-shell .child-bmi-typical{flex:3;background:#4ade80}
.tool-calculator-shell .child-bmi-risk{background:#facc15}
.tool-calculator-shell .child-bmi-high{background:#fb923c}
.tool-calculator-shell .child-bmi-obesity{display:none;background:#8b5cf6}
.tool-calculator-shell .child-bmi-marker{position:absolute;top:calc(2rem + .875rem);left:0;width:.95rem;height:.95rem;border:3px solid var(--ob-surface);border-radius:50%;background:var(--ob-primary);box-shadow:0 0 0 2px var(--ob-primary);transform:translate(-50%,-50%)}
.tool-calculator-shell .child-bmi-marker-label{position:absolute;top:.15rem;left:0;color:var(--ob-primary);font-size:.8rem;font-weight:700;white-space:nowrap;transform:translateX(-50%)}
.tool-calculator-shell .child-bmi-scale-labels{display:flex;justify-content:space-between;margin-top:.55rem;color:var(--ob-text-muted);font-size:.68rem}
.tool-calculator-shell .child-bmi-table{overflow-x:auto}
.tool-calculator-shell .child-bmi-table .bmi-interpretation-row{grid-template-columns:minmax(9rem,.8fr) minmax(10rem,1.2fr);min-width:23rem}
.tool-calculator-shell .child-bmi-table .child-bmi-row[hidden]{display:none}
.tool-calculator-shell .child-bmi-table .child-bmi-row.is-current{outline:2px solid var(--ob-primary);outline-offset:-2px;background:color-mix(in srgb,var(--ob-primary) 12%,var(--ob-surface))}
.tool-calculator-shell .child-bmi-table .child-bmi-row strong{color:var(--ob-text)}
.tool-calculator-shell .child-bmi-table .child-bmi-severe-row{background:color-mix(in srgb,#60a5fa 11%,var(--ob-surface))}
.tool-calculator-shell .child-bmi-table .child-bmi-low-row{background:color-mix(in srgb,#60a5fa 11%,var(--ob-surface))}
.tool-calculator-shell .child-bmi-table .child-bmi-typical-row{background:color-mix(in srgb,#4ade80 11%,var(--ob-surface))}
.tool-calculator-shell .child-bmi-table .child-bmi-risk-row{background:color-mix(in srgb,#facc15 11%,var(--ob-surface))}
.tool-calculator-shell .child-bmi-table .child-bmi-high-row{background:color-mix(in srgb,#fb923c 11%,var(--ob-surface))}
.tool-calculator-shell .child-bmi-table .child-bmi-obesity-row{background:color-mix(in srgb,#8b5cf6 11%,var(--ob-surface))}
.tool-calculator-shell .child-bmi-table .child-bmi-severe-row strong,
.tool-calculator-shell .child-bmi-table .child-bmi-low-row strong{color:#60a5fa}
.tool-calculator-shell .child-bmi-table .child-bmi-typical-row strong{color:#4ade80}
.tool-calculator-shell .child-bmi-table .child-bmi-risk-row strong{color:#facc15}
.tool-calculator-shell .child-bmi-table .child-bmi-high-row strong{color:#fb923c}
.tool-calculator-shell .child-bmi-table .child-bmi-obesity-row strong{color:#a78bfa}
.tool-calculator-shell .child-bmi-category-severe,.tool-calculator-shell .child-bmi-category-low{color:#60a5fa}
.tool-calculator-shell .child-bmi-category-typical{color:#4ade80}
.tool-calculator-shell .child-bmi-category-risk{color:#facc15}
.tool-calculator-shell .child-bmi-category-high{color:#fb923c}
.tool-calculator-shell .child-bmi-category-obesity{color:#a78bfa}
@media(max-width:520px){.tool-calculator-shell .child-bmi-section-heading p{font-size:.72rem}.tool-calculator-shell .child-bmi-table .bmi-interpretation-row{font-size:.7rem}.tool-calculator-shell .child-bmi-table .bmi-interpretation-row>*{padding:.55rem .6rem}}
@media(min-width:768px){.tool-calculator-shell .child-bmi-scale-track{height:2.5rem;border-radius:.85rem}.tool-calculator-shell .child-bmi-marker{top:calc(2rem + 1.25rem)}}

.tool-calculator-shell .bmi-dot{
    display:inline-block;
    width:.55rem;
    height:.55rem;
    margin-right:.35rem;
    border-radius:999px;
    vertical-align:middle;
}

.tool-calculator-shell .bmi-dot-blue{background:#60a5fa}
.tool-calculator-shell .bmi-dot-green{background:#4ade80}
.tool-calculator-shell .bmi-dot-yellow{background:#facc15}
.tool-calculator-shell .bmi-dot-orange{background:#fb923c}
.tool-calculator-shell .bmi-dot-red{background:#ef4444}
.tool-calculator-shell .bmi-dot-purple{background:#8b5cf6}

@media(max-width:767px){
    .tool-calculator-shell .bmi-scale-labels{
        grid-template-columns:repeat(6,minmax(0,1fr));
        gap:.15rem;
        font-size:.54rem;
    }

    .tool-calculator-shell .bmi-interpretation-row{
        grid-template-columns:minmax(5rem,.8fr) minmax(7rem,1.2fr) minmax(5rem,.8fr);
    }

    .tool-calculator-shell .bmi-interpretation-row>*{
        padding:.55rem .6rem;
    }
}

@media(max-width:520px){
    .tool-calculator-shell .bmi-result-main>p:first-child{
        font-size:1.8rem;
    }

    .tool-calculator-shell .bmi-scale-labels{
        font-size:.5rem;
    }

    .tool-calculator-shell .bmi-interpretation-header{
        display:none;
    }

    .tool-calculator-shell .bmi-interpretation-row{
        grid-template-columns:1fr;
        gap:.15rem;
        padding:.65rem .75rem;
    }

    .tool-calculator-shell .bmi-interpretation-row>*{
        padding:0;
    }
}


/* Tabele interpretacji WHR i WHtR - podświetlenie zakresu odpowiadającego wynikowi. */
.tool-calculator-shell .body-index-interpretation-row.is-current{
    outline:2px solid var(--ob-primary);
    outline-offset:-2px;
    font-weight:700;
}
.tool-calculator-shell .body-index-interpretation-row.is-current strong{
    text-decoration:underline;
    text-underline-offset:.15em;
}


/* WHR/WHtR: pojedynczy kafelek z wartością i opisem interpretacji. */
.tool-calculator-shell .body-index-result .body-index-single-card{display:block;margin-top:1.25rem;padding:1.15rem 1.25rem;border:2px solid var(--ob-primary);border-radius:.8rem;background:var(--ob-surface)}
.tool-calculator-shell .body-index-single-card .body-index-result-value{margin:.35rem 0 0;color:var(--ob-primary);font-size:2rem;font-weight:700;line-height:1.2}
.tool-calculator-shell .body-index-single-card .body-index-result-category{margin:.65rem 0 0;color:var(--ob-text);font-size:1rem;font-weight:700;line-height:1.5}
.tool-calculator-shell .body-index-single-card .body-index-result-threshold{margin:.4rem 0 0;color:var(--ob-text-secondary);font-size:.875rem;line-height:1.5}


/* Tabela interpretacji BMI w odpowiedziach FAQ: zachowuje układ tabeli narzędzia. */
.faq-bmi-table{width:100%;overflow-x:auto;border:1px solid var(--ob-border);border-radius:.7rem}
.faq-bmi-table .faq-bmi-row{display:grid;grid-template-columns:minmax(7rem,.9fr) minmax(9rem,1.35fr) minmax(7rem,.85fr);align-items:center;min-width:28rem;min-height:2.6rem;border-top:1px solid var(--ob-border);font-size:.75rem}
.faq-bmi-table .faq-bmi-row:first-child{border-top:0}
.faq-bmi-table .faq-bmi-row>*{min-width:0;padding:.65rem .8rem}
.faq-bmi-table .faq-bmi-row.bmi-category-under{background:color-mix(in srgb,#60a5fa 9%,var(--ob-surface))}
.faq-bmi-table .faq-bmi-row.bmi-category-normal{background:color-mix(in srgb,#4ade80 9%,var(--ob-surface))}
.faq-bmi-table .faq-bmi-row.bmi-category-over{background:color-mix(in srgb,#facc15 9%,var(--ob-surface))}
.faq-bmi-table .faq-bmi-row.bmi-category-obesity-1{background:color-mix(in srgb,#fb923c 9%,var(--ob-surface))}
.faq-bmi-table .faq-bmi-row.bmi-category-obesity-2{background:color-mix(in srgb,#ef4444 9%,var(--ob-surface))}
.faq-bmi-table .faq-bmi-row.bmi-category-obesity-3{background:color-mix(in srgb,#8b5cf6 9%,var(--ob-surface))}
.faq-bmi-table .faq-bmi-row strong{font-weight:600}
.faq-bmi-table .bmi-interpretation-header{display:grid;background:var(--ob-surface-soft);font-weight:700}
@media(max-width:520px){.faq-bmi-table .faq-bmi-row{grid-template-columns:minmax(7rem,.9fr) minmax(9rem,1.35fr) minmax(7rem,.85fr);font-size:.7rem}.faq-bmi-table .faq-bmi-row>*{padding:.55rem .6rem}}


/* Tabela stref tętna w FAQ - układ zgodny z tabelą w kalkulatorze. */
.faq-heart-zones{display:block!important;margin:0!important;padding:0!important;border:0!important}
.faq-heart-zones-table{width:100%;overflow-x:auto;border:1px solid var(--ob-border);border-radius:.7rem}
.faq-heart-zones-table .faq-heart-zone-row{display:grid;grid-template-columns:minmax(5.5rem,.8fr) minmax(7rem,1.2fr) minmax(6rem,.9fr);align-items:center;min-width:25rem;min-height:2.6rem;border-top:1px solid var(--ob-border);font-size:.75rem}
.faq-heart-zones-table .faq-heart-zone-row:first-child{border-top:0}
.faq-heart-zones-table .faq-heart-zone-row>*{min-width:0;padding:.65rem .8rem}
.faq-heart-zones-table .heart-zone-1{background:color-mix(in srgb,#60a5fa 9%,var(--ob-surface))}
.faq-heart-zones-table .heart-zone-2{background:color-mix(in srgb,#4ade80 9%,var(--ob-surface))}
.faq-heart-zones-table .heart-zone-3{background:color-mix(in srgb,#facc15 9%,var(--ob-surface))}
.faq-heart-zones-table .heart-zone-4{background:color-mix(in srgb,#fb923c 9%,var(--ob-surface))}
.faq-heart-zones-table .heart-zone-5{background:color-mix(in srgb,#8b5cf6 9%,var(--ob-surface))}
.faq-heart-zones-table .heart-zone-row strong{font-weight:600}
@media(max-width:520px){.faq-heart-zones-table .faq-heart-zone-row{grid-template-columns:minmax(5.5rem,.8fr) minmax(7rem,1.2fr) minmax(6rem,.9fr);font-size:.7rem}.faq-heart-zones-table .faq-heart-zone-row>*{padding:.55rem .6rem}}


/* Tabele FAQ mieszczą się w szerokości karty także na małych ekranach. */
.faq-bmi-table,
.faq-heart-zones-table{
    width:100%;
    max-width:100%;
    box-sizing:border-box;
    overflow-x:hidden;
}
.faq-bmi-table .faq-bmi-row,
.faq-heart-zones-table .faq-heart-zone-row{
    box-sizing:border-box;
    min-width:0;
}
.faq-bmi-table .faq-bmi-row>*,
.faq-heart-zones-table .faq-heart-zone-row>*{
    min-width:0;
    overflow-wrap:anywhere;
    word-break:normal;
}
@media(max-width:520px){
    .faq-bmi-table .faq-bmi-row{
        grid-template-columns:minmax(0,.85fr) minmax(0,1.35fr) minmax(0,.8fr);
        font-size:.68rem;
    }
    .faq-heart-zones-table .faq-heart-zone-row{
        grid-template-columns:minmax(0,.8fr) minmax(0,1.2fr) minmax(0,.9fr);
        font-size:.68rem;
    }
    .faq-bmi-table .faq-bmi-row>*,
    .faq-heart-zones-table .faq-heart-zone-row>*{
        padding:.5rem .35rem;
    }
}


/* WHR i WHtR: dopasuj wiersze tabel interpretacji do szerokości telefonu. */
@media(max-width:520px){
    .tool-calculator-shell .body-index-interpretation .bmi-interpretation-table{
        width:100%;
        max-width:100%;
        min-width:0;
        overflow:hidden;
        box-sizing:border-box;
    }
    .tool-calculator-shell .body-index-interpretation .bmi-interpretation-row{
        display:grid;
        grid-template-columns:minmax(0,1fr);
        gap:.3rem;
        width:100%;
        min-width:0;
        box-sizing:border-box;
    }
    .tool-calculator-shell .body-index-interpretation .bmi-interpretation-row>*{
        min-width:0;
        max-width:100%;
        white-space:normal;
        overflow-wrap:anywhere;
        word-break:normal;
        box-sizing:border-box;
    }
    .tool-calculator-shell .body-index-interpretation .bmi-interpretation-row strong{
        line-height:1.4;
    }
}

/* Shared validation error style for calculator forms. */
.tool-calculator-shell .tool-error[role="alert"]:not(.hidden) {
    display: flex !important;
    align-items: flex-start;
    gap: 0.7rem;
    width: 100% !important;
    margin: 0 0 1rem !important;
    padding: 0.65rem 0.8rem;
    box-sizing: border-box;
    border: 1px solid #ef4444 !important;
    border-radius: 0.85rem;
    background: transparent !important;
    color: var(--ob-text, inherit) !important;
    font: inherit;
    font-weight: 400 !important;
    line-height: 1.5;
    text-align: left !important;
}

.tool-calculator-shell .tool-error[role="alert"]:not(.hidden)::before {
    content: "!";
    display: grid;
    place-items: center;
    flex: 0 0 1.2rem;
    width: 1.2rem;
    height: 1.2rem;
    margin-top: 0.1rem;
    border: 1px solid #ef4444;
    border-radius: 50%;
    color: #ef4444;
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1;
}

@media (max-width: 600px) {
    .tool-calculator-shell .virtual-breathalyzer-datetime-field,
    .tool-calculator-shell .virtual-breathalyzer-date-time {
        display: grid;
        grid-template-columns: minmax(0, 1fr) !important;
        width: 100%;
        min-width: 0;
        max-width: 100%;
    }

    .tool-calculator-shell .virtual-breathalyzer-date-time > input {
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }
}

.tool-calculator-shell .math-fraction-calculation {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(12rem, 0.8fr) minmax(0, 1fr);
    align-items: center;
    gap: 1.25rem;
}

.tool-calculator-shell .math-fraction {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.tool-calculator-shell .math-fraction legend {
    margin-bottom: 0.75rem;
    color: var(--ob-text);
    font-weight: 650;
}

.tool-calculator-shell .math-fraction label,
.tool-calculator-shell .math-fraction-operation label {
    margin-bottom: 0.35rem;
}

.tool-calculator-shell .math-fraction-rule {
    height: 2px;
    margin: 0.65rem 0;
    border-radius: 2px;
    background: var(--ob-border);
}

.tool-calculator-shell .math-fraction-operation {
    min-width: 0;
}

.tool-calculator-shell .math-fraction-operation select {
    width: 100%;
}

.tool-calculator-shell .math-result-fraction {
    display: inline-grid;
    grid-template-rows: auto 2px auto;
    justify-items: center;
    gap: 0.12rem;
    min-width: 4rem;
    color: var(--ob-text);
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.15;
}

.tool-calculator-shell .math-result-mixed {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.tool-calculator-shell .math-result-mixed.hidden {
    display: none !important;
}

.tool-calculator-shell .math-result-whole {
    color: var(--ob-text);
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.15;
}

.tool-calculator-shell .math-result-fraction.hidden {
    display: none !important;
}

.tool-calculator-shell .math-result-fraction-rule {
    width: 100%;
    min-width: 3rem;
    height: 3px;
    border-radius: 2px;
    background: currentColor;
}

.tool-calculator-shell #math-result .math-result-card{
    border:2px solid var(--ob-primary)!important;
    background:var(--ob-surface)!important;
}
.tool-calculator-shell #math-result .math-result-mixed{
    min-height:3.5rem;
    gap:.7rem;
}
.tool-calculator-shell #math-result :is(.math-result-whole,.math-result-fraction){
    color:var(--ob-primary);
    font-size:2rem;
    font-weight:750;
}
.tool-calculator-shell #math-result .math-result-fraction{min-width:3.5rem}

.tool-calculator-shell .math-result-fraction.is-integer {
    grid-template-rows: auto;
}

.tool-calculator-shell .math-result-fraction.is-integer .math-result-fraction-rule,
.tool-calculator-shell .math-result-fraction.is-integer #math-fraction-denominator {
    display: none;
}

.tool-calculator-shell .math-sample-choice {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem;
    min-width: 0;
    margin: 0;
    padding: 0 !important;
    border: 0;
}

.tool-calculator-shell .math-sample-choice legend {
    grid-column: 1 / -1;
    margin-bottom: 0.35rem;
    color: var(--ob-text);
    font-weight: 650;
}

.tool-calculator-shell .math-sample-choice .math-sample-option {
    display: flex !important;
    align-items: flex-start;
    gap: 0.65rem;
    min-width: 0;
    margin: 0 !important;
    padding: 0.8rem 0.9rem;
    border: 1px solid var(--ob-border);
    border-radius: 0.75rem;
    background: var(--ob-surface-soft);
    cursor: pointer;
    transition: border-color 150ms ease, background-color 150ms ease;
}

.tool-calculator-shell .math-sample-choice .math-sample-option:has(input:checked) {
    border-color: var(--ob-primary);
    background: color-mix(in srgb, var(--ob-primary) 10%, var(--ob-surface));
}

.tool-calculator-shell .math-sample-choice .math-sample-option input {
    flex: 0 0 auto;
    width: 1rem;
    height: 1rem;
    margin: 0.15rem 0 0;
    accent-color: var(--ob-primary);
}

.tool-calculator-shell .math-sample-choice .math-sample-option span {
    display: grid;
    gap: 0.2rem;
    min-width: 0;
}

.tool-calculator-shell .math-sample-choice .math-sample-option strong {
    color: var(--ob-text);
    font-size: 0.9rem;
    font-weight: 650;
}

.tool-calculator-shell .math-sample-choice .math-sample-option small {
    color: var(--ob-text-secondary);
    font-size: 0.78rem;
    line-height: 1.4;
}

@media (max-width: 640px) {
    .tool-calculator-shell .math-fraction-calculation {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1rem;
    }

    .tool-calculator-shell .math-fraction-calculation > .math-fraction-operation {
        grid-column: 1 / -1;
        grid-row: 2;
    }
}

.tool-calculator-shell .weighted-grade-hint {
    margin: 0 0 0.85rem;
    color: var(--ob-text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
}

.tool-calculator-shell .weighted-grade-list {
    display: grid;
    gap: 0.75rem;
}

.tool-calculator-shell .weighted-grade-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
    align-items: end;
    gap: 0.75rem;
    padding: 0.85rem;
    border: 1px solid var(--ob-border);
    border-radius: 0.8rem;
    background: var(--ob-surface-soft);
}

.tool-calculator-shell .weighted-grade-row > div {
    min-width: 0;
}

.tool-calculator-shell .weighted-grade-row label {
    display: block;
    margin-bottom: 0.35rem;
    color: var(--ob-text-secondary);
    font-size: 0.8rem;
    font-weight: 600;
}

.tool-calculator-shell .weighted-grade-row .tool-control {
    min-height: 2.8rem;
}

.tool-calculator-shell .weighted-grade-remove,
.tool-calculator-shell .weighted-grade-add {
    min-height: 2.8rem;
    padding: 0.6rem 0.85rem;
    border: 1px solid var(--ob-border);
    border-radius: 0.7rem;
    color: var(--ob-text);
    background: var(--ob-surface);
    font: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
}

.tool-calculator-shell .weighted-grade-remove:hover,
.tool-calculator-shell .weighted-grade-add:hover {
    border-color: var(--ob-primary);
    color: var(--ob-primary);
}

.tool-calculator-shell .weighted-grade-add {
    margin-top: 0.75rem;
}

@media (max-width: 480px) {
    .tool-calculator-shell .weighted-grade-row {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 0.5rem;
    }

    .tool-calculator-shell .weighted-grade-remove {
        grid-column: 1 / -1;
        justify-self: start;
        min-height: 2.35rem;
    }
}

.tool-calculator-shell .unit-converter-unit-fields {
    grid-template-columns: minmax(0, 1fr) 3.25rem minmax(0, 1fr);
    align-items: end;
    gap: 0.75rem;
}

.tool-calculator-shell .unit-converter-swap {
    display: inline-flex;
    width: 3.25rem;
    min-width: 3.25rem;
    min-height: 3rem;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--ob-border);
    border-radius: 0.75rem;
    background: var(--ob-surface-soft);
    color: var(--ob-text-secondary);
    cursor: pointer;
    transition: border-color 160ms ease, color 160ms ease, background-color 160ms ease;
}

.tool-calculator-shell .unit-converter-swap:hover {
    border-color: var(--ob-primary);
    background: var(--ob-primary-light);
    color: var(--ob-primary);
}

.tool-calculator-shell .unit-converter-swap:focus-visible {
    outline: 2px solid var(--ob-primary);
    outline-offset: 2px;
}

.tool-calculator-shell .unit-converter-swap svg {
    width: 1.25rem;
    height: 1.25rem;
}

@media (max-width: 767px) {
    .tool-calculator-shell .unit-converter-unit-fields {
        grid-template-columns: minmax(0, 1fr);
    }

    .tool-calculator-shell .unit-converter-swap {
        justify-self: center;
        transform: rotate(90deg);
    }
}
.tool-calculator-shell .calculator-number-interpretation{
    display:block!important;
    grid-template-columns:minmax(0,1fr)!important;
    margin-top:1.5rem!important;
    padding:0!important;
    border:0!important;
    border-radius:0!important;
    background:transparent!important;
}

.tool-calculator-shell .calculator-number-interpretation .bmi-interpretation-heading{
    margin-bottom:1rem;
}

.tool-calculator-shell .calculator-number-interpretation .bmi-interpretation-heading p{
    margin:.35rem 0 0;
    line-height:1.55;
}

.tool-calculator-shell .calculator-number-table .bmi-interpretation-row{
    grid-template-columns:minmax(6.5rem,.45fr) minmax(0,1.55fr);
}

.tool-calculator-shell .calculator-number-table .bmi-interpretation-header{
    display:grid;
}

.tool-calculator-shell .calculator-number-table .calculator-number-row{
    background:var(--ob-surface)!important;
}

.tool-calculator-shell .calculator-number-table .calculator-number-row strong{
    color:var(--ob-text);
}

@media(max-width:520px){
    .tool-calculator-shell .calculator-number-interpretation{padding:.9rem!important}
    .tool-calculator-shell .calculator-number-table .bmi-interpretation-row{
        grid-template-columns:minmax(5rem,.5fr) minmax(0,1.5fr);
        font-size:.68rem;
    }
    .tool-calculator-shell .calculator-number-table .bmi-interpretation-row>*{padding:.55rem .6rem}
}

/* Wspólna typografia i stany kart nawigacji we wszystkich grupach narzędzi. */
.tool-calculator-shell :is(.health-weight-tab,.body-index-tab,[role=tablist] > [role=tab]){
    box-sizing:border-box;
    font-size:.8rem!important;
    font-weight:400!important;
    line-height:1.35!important;
    letter-spacing:normal!important;
    text-transform:none!important;
    text-decoration:none;
    color:var(--ob-text-secondary)!important;
    transition:background-color .15s ease,color .15s ease,border-color .15s ease,box-shadow .15s ease;
}
.tool-calculator-shell :is(.health-weight-tab,.body-index-tab,[role=tablist] > [role=tab]) > span:first-child{
    font-size:.8rem!important;
    font-weight:600!important;
    line-height:1.3!important;
}
.tool-calculator-shell :is(.health-weight-tab,.body-index-tab,[role=tablist] > [role=tab]) > span:last-child{
    font-size:.74rem!important;
    font-weight:400!important;
    line-height:1.3!important;
}
.tool-calculator-shell :is(.health-weight-tab,.body-index-tab,[role=tablist] > [role=tab]):is([aria-current=page],[aria-selected=true]){
    color:var(--ob-primary)!important;
    background:var(--ob-surface-soft)!important;
}
.tool-calculator-shell :is(.health-weight-tab,.body-index-tab,[role=tablist] > [role=tab]):is(:hover,:focus-visible){
    color:var(--ob-primary)!important;
    background:var(--ob-surface-soft)!important;
}
@media(max-width:640px){
    .tool-calculator-shell :is(.health-weight-tab,.body-index-tab,[role=tablist] > [role=tab]) > span:last-child{font-size:.68rem!important}
}
.affiliate-offers-section{width:100%;margin:0 auto;padding:1.25rem;border:1px solid var(--ob-border);border-radius:1rem;background:var(--ob-surface)}
.affiliate-offers-heading h2{margin:.2rem 0 0;color:var(--ob-text);font-size:1.25rem;font-weight:700}
.affiliate-updated{margin:.35rem 0 0;color:var(--ob-text-secondary);font-size:.75rem}
.affiliate-offers-heading p:not(.affiliate-eyebrow){margin:.35rem 0 0;color:var(--ob-text-secondary);font-size:.85rem}
.affiliate-eyebrow{margin:0;color:var(--ob-primary-light);font-size:.68rem;font-weight:700;letter-spacing:.14em}
.affiliate-offers-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.75rem;margin-top:1rem}
.affiliate-offer-card{position:relative;display:flex;min-width:0;flex-direction:column;padding:1rem;border:1px solid var(--ob-border);border-radius:.8rem;background:var(--ob-surface-soft)}
.affiliate-ad-badge{position:absolute;top:.65rem;right:.65rem;color:var(--ob-text-muted);font-size:.58rem;font-weight:700;letter-spacing:.08em}
.affiliate-offer-partner{margin:0;color:var(--ob-text-secondary);font-size:.72rem;font-weight:600}
.affiliate-offer-name{margin:.35rem 0 0;padding-right:3.5rem;color:var(--ob-text);font-size:1rem;font-weight:700}
.affiliate-offer-campaign{min-height:2.8rem;margin:.5rem 0 1rem;color:var(--ob-text-secondary);font-size:.75rem;line-height:1.45}
.affiliate-offer-link{display:inline-flex;align-items:center;justify-content:space-between;gap:.5rem;margin-top:auto;padding:.55rem .7rem;border-radius:.55rem;background:var(--ob-primary);color:#fff;font-size:.75rem;font-weight:700;text-decoration:none}
.affiliate-offer-link:hover{background:var(--ob-primary-hover)}
.affiliate-favorite-badge{position:absolute;top:.8rem;right:.8rem;padding:.2rem .45rem;border-radius:999px;color:#ffd98a;background:#49361a;font-size:.68rem;font-weight:700}
.affiliate-offer-card.is-favorite{border-color:#b584ff;box-shadow:0 0 0 1px #8b45f655}
.affiliate-offer-comparison{display:grid;gap:.35rem;margin:0 0 1rem;font-size:.78rem}
.affiliate-offer-comparison div{display:flex;justify-content:space-between;gap:.75rem;border-top:1px solid #ffffff12;padding-top:.35rem}
.affiliate-offer-comparison dt{color:var(--ob-text-muted)}
.affiliate-offer-comparison dd{margin:0;color:var(--ob-text);text-align:right}
.affiliate-ad-label{align-self:center;border:1px solid var(--ob-border);border-radius:999px;padding:.4rem .7rem;color:var(--ob-text-secondary);font-size:.7rem}.affiliate-offer-row{display:block;padding:0;background:var(--ob-surface);overflow:hidden}.affiliate-offer-main{display:grid;grid-template-columns:2rem minmax(180px,1.3fr) minmax(180px,1fr) auto;gap:.8rem;align-items:center;padding:.85rem 1rem;border-bottom:1px solid var(--ob-border)}.affiliate-offer-rank{display:grid;place-items:center;width:1.8rem;height:1.8rem;border:1px solid #7651ad;border-radius:.45rem;background:#30224b;color:#e0c9ff;font-weight:700}.affiliate-offer-brand{display:flex;align-items:center;gap:.6rem}.affiliate-offer-brand small{display:block;color:var(--ob-text-muted);font-size:.65rem}.affiliate-offer-title{color:var(--ob-primary-light);font-weight:700}.affiliate-offer-actions{display:flex;gap:.45rem}.affiliate-offer-details{border:1px solid var(--ob-border);border-radius:.55rem;padding:.5rem .7rem;color:var(--ob-text);font-size:.72rem;font-weight:700;text-decoration:none;background:transparent}.affiliate-offer-actions .affiliate-offer-link{margin:0}.affiliate-offer-details-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:.7rem;padding:.75rem 1rem}.affiliate-offer-details-grid small{display:block;color:var(--ob-text-muted);font-size:.62rem}.affiliate-offer-details-grid strong,.affiliate-offer-details-grid span{display:block;margin-top:.2rem;color:var(--ob-text);font-size:.72rem}.affiliate-offer-promo{display:flex;justify-content:space-between;gap:.7rem;margin:0 1rem .65rem;padding:.55rem .7rem;border:1px solid #4a3b65;border-radius:.5rem;background:#211a31;color:#d8c8fa;font-size:.7rem}.affiliate-offer-promo b{padding:.2rem .4rem;border-radius:.3rem;background:#7d52d9;color:#fff;font-size:.65rem}.affiliate-offer-expand{display:block;width:100%;border:0;border-top:1px solid var(--ob-border);padding:.55rem;background:transparent;color:var(--ob-primary-light);font-size:.75rem}.affiliate-offer-row .affiliate-offer-comparison{display:none}.affiliate-offer-row.is-expanded .affiliate-offer-comparison{display:grid;padding:0 1rem 1rem}.affiliate-offer-row .affiliate-offer-expand{cursor:pointer}.affiliate-offer-row .affiliate-offer-logo{width:2.4rem;height:2.4rem}.affiliate-offer-row .affiliate-offer-partner{margin:0;color:var(--ob-text);font-size:.8rem}.affiliate-offer-row .affiliate-offer-name,.affiliate-offer-row .affiliate-offer-campaign{display:none}
@media(max-width:760px){.affiliate-offers-heading{display:block}.affiliate-ad-label{display:inline-block;margin-top:.7rem}.affiliate-offer-main{grid-template-columns:2rem 1fr;gap:.6rem}.affiliate-offer-title{grid-column:2}.affiliate-offer-actions{grid-column:2}.affiliate-offer-details-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.affiliate-offer-promo{margin-left:.7rem;margin-right:.7rem}}
@media(max-width:760px){.affiliate-offers-grid{grid-template-columns:1fr}.affiliate-offers-section{padding:1rem}}
.affiliate-offers-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:1rem}.affiliate-offers-grid{display:flex;flex-direction:column;gap:.7rem}.affiliate-offer-row{position:relative;display:block;padding:0;overflow:hidden;border:1px solid var(--ob-border);border-radius:.85rem;background:var(--ob-surface);box-shadow:0 5px 18px #00000012}.affiliate-offer-row.is-favorite{border-color:#7954b5;box-shadow:0 0 0 1px #8b5cf633}.affiliate-offer-row .affiliate-ad-badge{z-index:1;top:.55rem;right:.65rem;padding:.16rem .35rem;border:1px solid var(--ob-border);border-radius:999px;background:var(--ob-surface);font-size:.55rem}.affiliate-offer-main{display:grid;grid-template-columns:2rem 3rem minmax(140px,1.15fr) minmax(260px,2fr) auto;gap:.75rem;align-items:center;padding:.8rem 1rem}.affiliate-offer-rank{display:grid;place-items:center;width:1.85rem;height:1.85rem;border:1px solid #7651ad;border-radius:.45rem;background:#30224b;color:#e0c9ff;font-size:.8rem;font-weight:750}.affiliate-offer-brand{display:grid;place-items:center;width:3rem;height:3rem}.affiliate-offer-logo{display:block;width:3rem;height:3rem;object-fit:contain;border:1px solid var(--ob-border);border-radius:.65rem;background:var(--ob-surface-soft);padding:.3rem}.affiliate-offer-logo-fallback{display:grid;place-items:center;color:var(--ob-primary-light);font-size:.68rem;font-weight:800}.affiliate-offer-identity{min-width:0}.affiliate-offer-identity .affiliate-offer-partner{color:var(--ob-text);font-size:.82rem;font-weight:700}.affiliate-offer-identity .affiliate-offer-title{display:block;margin:.2rem 0 0;padding:0;color:var(--ob-primary-light);font-size:.88rem;line-height:1.35}.affiliate-offer-facts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.45rem}.affiliate-offer-facts>div{min-width:0;border-left:1px solid var(--ob-border);padding:0 .55rem}.affiliate-offer-facts small{display:block;color:var(--ob-text-muted);font-size:.62rem}.affiliate-offer-facts strong{display:block;margin-top:.2rem;color:var(--ob-text);font-size:.72rem;line-height:1.35;overflow-wrap:anywhere}.affiliate-offer-row .affiliate-offer-link{white-space:nowrap;margin:0;padding:.55rem .75rem;border:1px solid var(--ob-primary);border-radius:.55rem;background:var(--ob-primary);color:#fff;font-size:.76rem}.affiliate-offer-row .affiliate-offer-link:hover{background:var(--ob-primary-hover);color:#fff}.affiliate-offer-promo{display:flex;align-items:center;gap:.55rem;margin:0 .9rem .7rem;padding:.5rem .65rem;border:1px solid #4a3b65;border-radius:.5rem;background:var(--ob-surface-soft);color:var(--ob-text-secondary);font-size:.72rem;line-height:1.4}.affiliate-offer-promo>span:first-child{flex:0 0 auto;color:var(--ob-primary-light)}.affiliate-offer-details{border-top:1px solid var(--ob-border)}.affiliate-offer-details>summary{position:relative;padding:.55rem 2rem;color:var(--ob-primary-light);font-size:.73rem;font-weight:650;text-align:center;cursor:pointer;list-style:none}.affiliate-offer-details>summary::-webkit-details-marker{display:none}.affiliate-offer-details>summary:after{content:"⌄";position:absolute;margin-left:.45rem;transition:transform .15s}.affiliate-offer-details[open]>summary:after{transform:rotate(180deg)}.affiliate-offer-details-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.5rem;margin:0;padding:.2rem .9rem .85rem}.affiliate-offer-details-grid>div{min-width:0;padding:.55rem .65rem;border:1px solid var(--ob-border);border-radius:.5rem;background:var(--ob-surface-soft)}.affiliate-offer-details-grid dt{color:var(--ob-text-muted);font-size:.65rem}.affiliate-offer-details-grid dd{margin:.2rem 0 0;color:var(--ob-text);font-size:.72rem;line-height:1.45;overflow-wrap:anywhere}.affiliate-ad-label{white-space:nowrap}
@media(max-width:1050px){.affiliate-offer-main{grid-template-columns:2rem 2.7rem minmax(130px,1fr) auto}.affiliate-offer-brand,.affiliate-offer-logo{width:2.7rem;height:2.7rem}.affiliate-offer-facts{grid-column:3/5;grid-row:2}.affiliate-offer-facts>div:first-child{border-left:0;padding-left:0}.affiliate-offer-row .affiliate-offer-link{grid-column:4;grid-row:1}}
@media(max-width:760px){.affiliate-offers-heading{display:flex;align-items:flex-start}.affiliate-offer-main{grid-template-columns:1.9rem 2.5rem minmax(0,1fr) auto;gap:.55rem;padding:.7rem}.affiliate-offer-brand,.affiliate-offer-logo{width:2.5rem;height:2.5rem}.affiliate-offer-identity{padding-right:2.8rem}.affiliate-offer-identity .affiliate-offer-title{font-size:.82rem}.affiliate-offer-facts{grid-column:1/-1;grid-row:2;gap:.25rem}.affiliate-offer-facts>div{padding:0 .4rem}.affiliate-offer-facts>div:first-child{padding-left:0}.affiliate-offer-facts strong{font-size:.68rem}.affiliate-offer-row .affiliate-offer-link{grid-column:4;grid-row:1;padding:.45rem .6rem}.affiliate-offer-promo{margin:0 .65rem .6rem;font-size:.68rem}.affiliate-offer-details-grid{grid-template-columns:1fr}.affiliate-ad-label{font-size:.62rem;padding:.3rem .5rem}}
.affiliate-offer-row details.affiliate-offer-details{display:block;border:0;border-top:1px solid var(--ob-border);border-radius:0;padding:0;background:transparent}
/* Affiliate comparison facts: five columns on desktop, two on mobile. */
.affiliate-offer-facts{grid-template-columns:repeat(5,minmax(0,1fr))}
@media(max-width:760px){.affiliate-offer-facts{grid-template-columns:repeat(2,minmax(0,1fr))}}
