/* Hamco free tools: shared file (created by TOOL-SIZE-1, 2026-11-01). Each tool appends ONE block
   between its own start and end markers, scoped to its own [data-hamco-tool] so no tool
   restyles another tool or the theme. */

/* ==== TOOL-SIZE-1 start (append to assets/css/tools.css; shared file from TOOL-PRICE-1) ==== */
/* Part A: the size finder's own base. Same declarations as the QA build (fragments/tools.size.css Part A),
   scoped to the size finder ([data-hamco-tool="size"], [data-hamco-tool-result="size"]) so they never restyle
   the price or deadline calculators that share this file. The attribute selector outranks the shared
   one-class rules above, so the order of the sibling blocks in this file does not matter. */
.tool-calc[data-hamco-tool="size"] { max-width: 640px; margin: 0 auto; }
[data-hamco-tool="size"] .tool-calc__field { border: 0; margin: 0 0 20px; padding: 0; min-width: 0; }
[data-hamco-tool="size"] .tool-calc__label { display: block; font-weight: 600; font-size: 1.05rem; color: var(--text-dark); margin: 0 0 6px; padding: 0; }
[data-hamco-tool="size"] .tool-calc__hint { color: #666; font-size: 0.95rem; margin: 0 0 8px; }
[data-hamco-tool="size"] .tool-calc__input { width: 100%; max-width: 220px; min-height: 44px; padding: 10px 12px; font-size: 1rem; border: 1px solid #ccc; border-radius: 8px; }
[data-hamco-tool="size"] .tool-calc__input[aria-invalid="true"] { border-color: var(--accent-red); }
[data-hamco-tool="size"] .tool-calc__error { color: var(--accent-red); font-size: 0.95rem; margin: 6px 0 0; }
[data-hamco-tool="size"] .tool-calc__actions { margin: 24px 0 12px; }
[data-hamco-tool="size"] .tool-calc__note,
[data-hamco-tool-result="size"] .tool-calc__note { color: #666; font-size: 0.95rem; margin: 8px 0 0; }
.tool-calc__result[data-hamco-tool-result="size"] { max-width: 640px; margin: 30px auto 0; padding: 24px; background: #fff; border: 1px solid #e0e0e0; border-left: 4px solid var(--accent-red); border-radius: 12px; }
[data-hamco-tool-result="size"] .tool-calc__head { font-size: 1.4rem; margin: 0 0 10px; color: var(--text-dark); }
[data-hamco-tool-result="size"] .tool-calc__head:focus { outline: none; }
[data-hamco-tool="size"] [hidden], [data-hamco-tool-result="size"] [hidden], [data-hamco-tool-result="size"][hidden] { display: none !important; }

/* Part B: size finder only. */
.tool-calc-section { padding: 80px 0; background: #fff; }
.tool-calc-section h2 { text-align: center; font-size: 2.5rem; margin-bottom: 15px; color: var(--text-dark); text-transform: uppercase; letter-spacing: 1px; }
.tool-calc-section .tool-calc-section__intro { text-align: center; color: #666; font-size: 1.1rem; max-width: 640px; margin: 0 auto 30px; }
.tool-calc__choices { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; }
.tool-calc__choice { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 16px; border: 1px solid #ccc; border-radius: 30px; cursor: pointer; background: #fff; }
.tool-calc__choice input { margin: 0; accent-color: var(--accent-red); }
.tool-calc__choice:has(input:checked) { border-color: var(--accent-red); }
.tool-calc__unit-input { display: inline-flex; align-items: center; gap: 8px; }
.tool-calc__suffix { color: #666; }
.tool-calc__fixed { margin: 16px 0; padding-left: 20px; color: #333; }
.tool-calc__fixed li { margin-bottom: 6px; }
[data-hamco-tool-result="size"] .body-cta { margin: 20px 0 10px; }
[data-hamco-tool-result="size"] .reply-note { color: #666; font-size: 0.95rem; margin: 0; }
.tool-calc-embed-code { display: block; max-width: 800px; margin: 0 auto 16px; padding: 16px; background: #f8f9fa; border: 1px solid #e0e0e0; border-radius: 8px; font-size: 0.9rem; white-space: pre-wrap; overflow-wrap: anywhere; }
.tool-calc-embed-actions { text-align: center; }
.tool-calc-embed-actions [hidden] { display: none !important; }

/* Embed route body (no theme stylesheet is loaded there, so the button is styled here).
   max-width: none keeps the body full width: the shared .tool-embed rule above is for the code box. */
body.tool-embed { margin: 0; max-width: none; font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; color: #333; background: #fff; --accent-red: #fe0000; --text-dark: #1a1a1a; }
.tool-embed__main { padding: 16px; }
.tool-embed__intro { margin: 0 0 16px; }
.tool-embed__credit { font-size: 0.85rem; margin: 20px 0 0; }
body.tool-embed .btn { display: inline-block; min-height: 44px; padding: 12px 28px; border: 0; border-radius: 30px; background: var(--accent-red); color: #fff; font-weight: 600; font-size: 1rem; text-decoration: none; cursor: pointer; }

@media (max-width: 768px) {
    .tool-calc-section { padding: 60px 0; }
    .tool-calc-section h2 { font-size: 2rem; }
    .tool-calc__result[data-hamco-tool-result="size"] { padding: 18px; }
}
@media (max-width: 480px) {
    .tool-calc__choice { flex: 1 1 100%; }
    [data-hamco-tool="size"] .tool-calc__input { max-width: 100%; }
    .tool-calc__unit-input { display: flex; }
}
/* ==== TOOL-SIZE-1 end ==== */

/* ==== CALC-HUB-1 start (price + deadline calculators on the sport pages; embeds) ==== */
/* Each tool scoped with zero weight (:where) to its own wrapper in the sport page section
   (.tool-section [data-hamco-calc]) and to its own embed body ([data-hamco-embed]); declarations are the
   QA-passed ones, unchanged. Section layout: category-pages.css .tool-section. */
/* -- price calculator (TOOL-PRICE-1) -- */

/* Anything a tool hides with the hidden attribute stays hidden, whatever the theme's display rules say. */
:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc [hidden],
:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__result [hidden],
:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__result[hidden],
:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .intro-section[data-tier-section][hidden],
:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-embed [hidden] {
    display: none !important;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc {
    margin: 0;
    max-width: 720px;
    font-family: var(--font-body, 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);
    color: var(--text-grey, #333);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__head {
    margin: 0 0 16px;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__field {
    margin: 0 0 16px;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__label {
    display: block;
    margin: 0 0 6px;
    font-weight: 700;
    color: var(--text-dark, #000);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__hint {
    margin: 0 0 6px;
    font-size: 0.9rem;
    color: #555;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__input,
:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__select {
    display: block;
    width: 100%;
    max-width: 420px;
    min-height: 44px;
    padding: 10px 12px;
    font: inherit;
    color: var(--text-dark, #000);
    background: #fff;
    border: 1px solid #c9cdd2;
    border-radius: var(--border-radius, 8px);
    box-sizing: border-box;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__input:focus,
:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__select:focus {
    outline: 2px solid var(--accent-red, #FE0000);
    outline-offset: 1px;
    border-color: var(--accent-red, #FE0000);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__input[aria-invalid="true"] {
    border-color: var(--accent-red, #FE0000);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__error {
    margin: 6px 0 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: #b00000;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__lines {
    margin: 0;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__line {
    margin: 0 0 16px;
    padding: 16px 16px 4px;
    background: var(--accent-light-grey, #F5F5F5);
    border-radius: var(--border-radius, 8px);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__actions {
    margin: 0 0 16px;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__remove {
    min-height: 44px;
    padding: 8px 0;
    font: inherit;
    font-size: 0.9rem;
    color: var(--accent-red, #FE0000);
    text-decoration: underline;
    background: none;
    border: 0;
    cursor: pointer;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__ship {
    margin: 0 0 8px;
    padding: 0;
    border: 0;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__ship label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    margin: 0 24px 0 0;
    cursor: pointer;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__note {
    margin: 0 0 8px;
    font-size: 0.95rem;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__empty {
    margin: 0;
    font-size: 1rem;
    color: #555;
}

/* Result box */
:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__result {
    max-width: 720px;
    margin: 24px 0 0;
    padding: 20px 24px;
    background: #fff;
    border: 1px solid #e6e8eb;
    border-left: 4px solid var(--accent-red, #FE0000);
    border-radius: var(--border-radius, 8px);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__tier {
    margin: 0 0 4px;
    font-size: 1.05rem;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__rows {
    margin: 12px 0;
    padding: 0;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    padding: 8px 0;
    border-bottom: 1px solid #eef0f2;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__row dt {
    margin: 0;
    font-weight: 600;
    color: var(--text-dark, #000);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__row dd {
    margin: 0;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__row--sub dt {
    font-weight: 400;
    color: #555;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__amount {
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__total {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    margin: 12px 0;
    padding: 12px 0 0;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-dark, #000);
    border-top: 2px solid var(--text-dark, #000);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__total strong {
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__hint-next {
    margin: 0 0 8px;
    font-weight: 600;
    color: var(--text-dark, #000);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__offer {
    margin: 0 0 8px;
    padding: 10px 12px;
    background: var(--accent-light-grey, #F5F5F5);
    border-radius: var(--border-radius, 8px);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__result .source-note {
    margin: 12px 0 0;
    font-size: 0.9rem;
    color: #555;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__credit {
    margin: 16px 0 0;
    font-size: 0.85rem;
    color: #555;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__credit a {
    color: var(--accent-red, #FE0000);
}

/* "Put this on your site" box */
:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-embed {
    max-width: 720px;
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-embed__code {
    margin: 0 0 12px;
    padding: 14px 16px;
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-all;
    font-size: 0.85rem;
    line-height: 1.5;
    color: var(--text-dark, #000);
    background: var(--accent-light-grey, #F5F5F5);
    border: 1px solid #e6e8eb;
    border-radius: var(--border-radius, 8px);
}

:where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-embed__copy {
    min-height: 44px;
}

/* Embed route: a bare page inside another site's iframe */
.tool-embed-page:where([data-hamco-embed="price"]) {
    margin: 0;
    padding: 16px;
    background: #fff;
    font-family: var(--font-body, 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);
    color: #333;
}

.tool-embed-page:where([data-hamco-embed="price"]) .tool-calc,
.tool-embed-page:where([data-hamco-embed="price"]) .tool-calc__result {
    max-width: none;
}

.tool-embed-page:where([data-hamco-embed="price"]) .btn {
    display: inline-block;
    padding: 12px 24px;
    font-weight: 700;
    text-decoration: none;
    border-radius: var(--border-radius, 8px);
}

.tool-embed-page:where([data-hamco-embed="price"]) .btn-primary {
    color: #fff;
    background: #FE0000;
}

.tool-embed-page:where([data-hamco-embed="price"]) .btn-secondary {
    color: #FE0000;
    background: #fff;
    border: 2px solid #FE0000;
}

/* Phones (412 px and below 768 px) */
@media (max-width: 768px) {
    :where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__input,
    :where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__select {
        max-width: none;
        font-size: 16px; /* no zoom on focus in iOS */
    }
    :where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__line {
        padding: 12px 12px 2px;
    }
    :where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__result {
        padding: 16px;
    }
    :where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__row,
    :where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__total {
        flex-wrap: wrap;
        gap: 4px 12px;
    }
    :where(.tool-section [data-hamco-calc="price"], [data-hamco-embed="price"]) .tool-calc__ship label {
        margin-right: 16px;
    }
    .tool-embed-page:where([data-hamco-embed="price"]) {
        padding: 12px;
    }
}
/* -- deadline calculator (TOOL-DEADLINE-1 r2) -- */
/* Part A: the tool-calc base, byte-identical to TOOL-SIZE-1 Part A. TOOL-PRICE-1 owns it in tools.css.
   At merge keep ONE copy: if tools.css already styles these selectors, drop Part A and keep Part B only.
   Colors from the theme variables only (--accent-red #FE0000, --text-dark, live combined CSS 2026-10-31). */
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc { max-width: 640px; margin: 0 auto; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__field { border: 0; margin: 0 0 20px; padding: 0; min-width: 0; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__label { display: block; font-weight: 600; font-size: 1.05rem; color: var(--text-dark); margin: 0 0 6px; padding: 0; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__hint { color: #666; font-size: 0.95rem; margin: 0 0 8px; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__input { box-sizing: border-box; width: 100%; max-width: 220px; min-height: 44px; padding: 10px 12px; font-size: 1rem; border: 1px solid #ccc; border-radius: 8px; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__input[aria-invalid="true"] { border-color: var(--accent-red); }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__error { color: var(--accent-red); font-size: 0.95rem; margin: 6px 0 0; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__actions { margin: 24px 0 12px; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__note { color: #666; font-size: 0.95rem; margin: 8px 0 0; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__result { max-width: 640px; margin: 30px auto 0; padding: 24px; background: #fff; border: 1px solid #e0e0e0; border-left: 4px solid var(--accent-red); border-radius: 12px; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__head { font-size: 1.4rem; margin: 0 0 10px; color: var(--text-dark); }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__head:focus { outline: none; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) [data-hamco-tool] [hidden], :where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) [data-hamco-tool-result] [hidden], :where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) [data-hamco-tool-result][hidden] { display: none !important; }

/* Part B: deadline calculator, embed code box and embed route body. */
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__rows { margin: 0 0 16px; padding: 0; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__row { display: flex; flex-wrap: wrap; gap: 4px 8px; margin: 0 0 8px; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__row dt { font-weight: 600; margin: 0; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__row dd { margin: 0; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__date { white-space: nowrap; font-weight: 600; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__verdict { margin: 16px 0 0; padding: 12px 16px; border-radius: 8px; background: #f8f9fa; border-left: 4px solid #999; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__verdict--ok { border-left-color: #2e7d32; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__verdict--tight { border-left-color: var(--text-dark); }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__verdict--early { border-left-color: var(--accent-red); }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__verdict a { color: inherit; text-decoration: underline; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__credit { font-size: 0.85rem; margin: 20px 0 0; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-embed { max-width: 800px; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-embed__code { display: block; margin: 0 0 16px; padding: 16px; background: #f8f9fa; border: 1px solid #e0e0e0; border-radius: 8px; font-size: 0.9rem; white-space: pre-wrap; overflow-wrap: anywhere; max-width: 100%; }
:where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-embed__copy { min-height: 44px; }

/* Embed route: no theme stylesheet loads there, so base type and the button are set here. */
body.tool-embed-page:where([data-hamco-embed="deadline"]) { margin: 0; padding: 16px; font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; color: #333; background: #fff; --accent-red: #FE0000; --text-dark: #000000; }
body.tool-embed-page:where([data-hamco-embed="deadline"]) h1 { font-size: 1.4rem; margin: 0 0 16px; color: var(--text-dark); }
body.tool-embed-page:where([data-hamco-embed="deadline"]) .btn { display: inline-block; min-height: 44px; padding: 12px 28px; border: 0; border-radius: 30px; background: var(--accent-red); color: #fff; font-weight: 600; font-size: 1rem; text-decoration: none; cursor: pointer; }
body.tool-embed-page:where([data-hamco-embed="deadline"]) .body-cta { margin: 20px 0 0; }

@media (max-width: 768px) {
    :where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__result { padding: 18px; }
}
@media (max-width: 480px) {
    :where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__input { max-width: 100%; }
    :where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-calc__row { display: block; }
    :where(.tool-section [data-hamco-calc="deadline"], [data-hamco-embed="deadline"]) .tool-embed__copy { width: 100%; }
}
/* ==== CALC-HUB-1 end ==== */
