/* Halmo notowania - premium frontend UI. Uses --hm-* tokens with hard
   fallbacks so it works whether or not the Kadence bridge is active. */
.halmo-notowania {
    --_ink: var(--hm-ink, #122033);
    --_ink-strong: #07152a;
    --_muted: var(--hm-muted, #65728a);
    --_line: var(--hm-line, #dde7ef);
    --_line-strong: #cdd9e5;
    --_surface: var(--hm-surface, #ffffff);
    --_surface-soft: #f6f9fb;
    --_surface-tint: #eef7f3;
    --_primary: var(--hm-primary, #007a4d);
    --_primary-dark: color-mix(in srgb, var(--_primary) 78%, #062013);
    --_primary-soft: color-mix(in srgb, var(--_primary) 10%, #ffffff);
    --_accent: var(--hm-accent, #f2714e);
    --_danger: var(--hm-danger, #c63d31);
    --_danger-soft: color-mix(in srgb, var(--_danger) 10%, #ffffff);
    --_radius-lg: 22px;
    --_radius-md: 16px;
    --_shadow-sm: 0 8px 24px rgba(15, 35, 52, .07);
    --_shadow-md: 0 18px 48px rgba(15, 35, 52, .12);
    color: var(--_ink);
    font-family: var(--hm-font-base, inherit);
    width: 100%;
    max-width: none;
    margin: 0 auto;
}
.halmo-notowania * { box-sizing: border-box; }

.halmo-not__toolbar {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
    margin: 0 0 12px;
    padding: 14px;
    border: 1px solid color-mix(in srgb, var(--_line) 86%, #ffffff);
    border-radius: var(--_radius-lg);
    background:
        radial-gradient(circle at 12% 10%, color-mix(in srgb, var(--_primary) 10%, transparent) 0, transparent 34%),
        linear-gradient(135deg, #ffffff 0%, #fbfdfc 48%, #f4faf7 100%);
    box-shadow: var(--_shadow-sm);
}
.halmo-not__toolbar::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background: linear-gradient(90deg, color-mix(in srgb, var(--_primary) 28%, transparent), transparent 34%);
    opacity: .22;
}
.halmo-not__search,
.halmo-not__groupwrap,
.halmo-not__datewrap { position: relative; z-index: 1; }
.halmo-not__search {
    flex: 1 1 420px;
    min-width: 240px;
    min-height: 48px;
    padding: 11px 14px 11px 46px;
    border: 1px solid var(--_line-strong);
    border-radius: 15px;
    font-size: 15px;
    line-height: 1.3;
    background-color: rgba(255, 255, 255, .94);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2365728a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-3.5-3.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: 16px 50%;
    background-size: 18px 18px;
    color: var(--_ink-strong);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .85), 0 1px 2px rgba(16, 31, 46, .04);
    transition: border-color .18s ease, box-shadow .18s ease, background-color .18s ease;
}
.halmo-not__search::placeholder { color: color-mix(in srgb, var(--_muted) 78%, #ffffff); }
.halmo-not__search:focus-visible {
    border-color: color-mix(in srgb, var(--_primary) 62%, var(--_line));
    outline: 0;
    background-color: #ffffff;
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--_primary) 13%, transparent);
}
.halmo-not__groupwrap,
.halmo-not__datewrap {
    flex: 0 0 auto;
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 7px 8px 7px 15px;
    border: 1px solid var(--_line);
    border-radius: 15px;
    background: rgba(255, 255, 255, .9);
    color: var(--_muted);
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
    box-shadow: 0 1px 2px rgba(16, 31, 46, .04);
}
.halmo-not__group-filter,
.halmo-not__dates {
    min-height: 34px;
    padding: 6px 34px 6px 11px;
    border: 1px solid color-mix(in srgb, var(--_line) 80%, #ffffff);
    border-radius: 11px;
    background-color: var(--_surface-soft);
    color: var(--_ink-strong);
    font-size: 14px;
    font-weight: 700;
}
.halmo-not__group-filter:focus-visible,
.halmo-not__dates:focus-visible {
    outline: 0;
    border-color: color-mix(in srgb, var(--_primary) 56%, var(--_line));
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--_primary) 12%, transparent);
}
.halmo-not__groupwrap[hidden] { display: none !important; }

.halmo-not__meta {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    margin: 0 0 16px;
    padding: 7px 12px;
    border: 1px solid color-mix(in srgb, var(--_primary) 14%, var(--_line));
    border-radius: 999px;
    background: linear-gradient(180deg, #ffffff, var(--_primary-soft));
    color: color-mix(in srgb, var(--_ink) 82%, var(--_primary));
    font-size: 13px;
    font-weight: 700;
    line-height: 1.3;
    box-shadow: 0 6px 18px rgba(15, 35, 52, .05);
}
.halmo-not__meta:empty { display: none; }

.halmo-not__tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 2px;
    align-items: flex-end;
    margin: 0 0 24px;
    padding: 0 0 0 0;
    border-bottom: 1px solid var(--_line-strong);
    overflow-x: auto;
    scrollbar-width: thin;
}
.halmo-not__tab {
    appearance: none;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    margin: 0;
    padding: 0 17px;
    border: 1px solid transparent;
    border-bottom: 0;
    border-radius: 13px 13px 0 0;
    background: transparent;
    color: var(--_muted);
    font-size: 14px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
    box-shadow: none;
    text-decoration: none;
    transition: background .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.halmo-not__tab::after {
    content: "";
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: -1px;
    height: 3px;
    border-radius: 999px 999px 0 0;
    background: transparent;
    transition: background .18s ease, left .18s ease, right .18s ease;
}
.halmo-not__tab:hover {
    background: color-mix(in srgb, var(--_primary) 5%, #ffffff);
    color: var(--_ink-strong);
}
.halmo-not__tab.is-active {
    background: #ffffff;
    border-color: var(--_line-strong);
    color: var(--_primary-dark);
    box-shadow: 0 -8px 22px rgba(15, 35, 52, .06);
}
.halmo-not__tab.is-active::after {
    left: 0;
    right: 0;
    background: linear-gradient(90deg, var(--_primary), color-mix(in srgb, var(--_primary) 58%, #2ecf8d));
}
.halmo-not__tab.is-empty-current:not(.is-active) {
    color: color-mix(in srgb, var(--_muted) 56%, #ffffff);
}
.halmo-not__tab:focus-visible {
    outline: 0;
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--_primary) 12%, transparent);
}
.halmo-not__tab-label {
    display: inline-block;
    text-transform: none;
    white-space: nowrap;
}
.halmo-not__tab-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 22px;
    padding: 0 8px;
    border-radius: 999px;
    background: color-mix(in srgb, var(--_muted) 12%, #ffffff);
    color: color-mix(in srgb, var(--_muted) 80%, #0f172a);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .02em;
}
.halmo-not__tab.is-active .halmo-not__tab-count {
    background: var(--_primary-soft);
    color: var(--_primary-dark);
}

.halmo-not__body { width: 100%; }
.halmo-not__section { margin: 0 0 26px; }
.halmo-not__section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 10px;
}
.halmo-not__cat-label {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--_primary-dark);
    font-family: var(--hm-font-head, inherit);
    font-size: clamp(16px, 1.4vw, 20px);
    font-weight: 900;
    line-height: 1.2;
    letter-spacing: .01em;
}
.halmo-not__cat-label::before {
    content: "";
    width: 9px;
    height: 26px;
    border-radius: 999px;
    background: linear-gradient(180deg, var(--_primary), color-mix(in srgb, var(--_primary) 50%, #7fd8aa));
    box-shadow: 0 6px 14px color-mix(in srgb, var(--_primary) 28%, transparent);
}
.halmo-not__cat-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    min-height: 26px;
    padding: 2px 9px;
    border: 1px solid color-mix(in srgb, var(--_primary) 14%, var(--_line));
    border-radius: 999px;
    background: var(--_primary-soft);
    color: var(--_primary-dark);
    font-size: 12px;
    font-weight: 900;
}
.halmo-not__table-wrap {
    width: 100%;
    overflow: auto;
    border: 1px solid var(--_line);
    border-radius: 20px;
    background: var(--_surface);
    box-shadow: var(--_shadow-sm);
}
.halmo-not__table {
    width: 100%;
    min-width: 820px;
    margin: 0;
    border: 0;
    border-collapse: separate;
    border-spacing: 0;
    background: var(--_surface);
}
.halmo-not__table caption { display: none; }
.halmo-not__table th,
.halmo-not__table td {
    text-align: left;
    padding: 14px 16px;
    border: 0;
    border-bottom: 1px solid color-mix(in srgb, var(--_line) 78%, #ffffff);
    vertical-align: middle;
    font-size: 15px;
    line-height: 1.35;
}
.halmo-not__table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: linear-gradient(180deg, #f9fcfb 0%, #eef5f2 100%);
    border-bottom: 1px solid var(--_line-strong);
    color: color-mix(in srgb, var(--_muted) 84%, var(--_ink));
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
    white-space: nowrap;
}
.halmo-not__table tbody tr:last-child td { border-bottom: 0; }
.halmo-not__table tbody tr:nth-child(even) td {
    background: color-mix(in srgb, var(--_surface-soft) 62%, #ffffff);
}
.halmo-not__table tbody tr:hover td {
    background: color-mix(in srgb, var(--_primary) 5%, #ffffff);
}
.halmo-not__row { transition: background .18s ease, transform .18s ease; }
.halmo-not__c-name { width: 36%; font-weight: 800; color: var(--_ink-strong); }
.halmo-not__c-unit { width: 13%; color: var(--_muted); font-weight: 700; }
.halmo-not__c-import { width: 14%; color: var(--_muted); font-weight: 800; white-space: nowrap; }
.halmo-not__c-price { width: 17%; white-space: nowrap; color: var(--_ink); font-weight: 700; }
.halmo-not__c-avg { width: 20%; white-space: nowrap; color: var(--_primary-dark); font-weight: 900; }
.halmo-not__table th.halmo-not__c-import,
.halmo-not__table th.halmo-not__c-avg { color: color-mix(in srgb, var(--_muted) 84%, var(--_ink)); }
.halmo-not__avg-wrap {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 34px;
    padding: 3px 5px 3px 11px;
    border: 1px solid color-mix(in srgb, var(--_primary) 13%, var(--_line));
    border-radius: 999px;
    background: linear-gradient(180deg, #ffffff, var(--_primary-soft));
}
.halmo-not__avg-value { color: var(--_primary-dark); font-variant-numeric: tabular-nums; }
.halmo-not__c-avg .halmo-not__trend { width: 28px; height: 28px; }
.halmo-not__c-avg .halmo-not__trend-icon { width: 18px; height: 18px; }

.halmo-not__import-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    max-width: 100%;
    min-height: 28px;
    padding: 4px 10px;
    border: 1px solid color-mix(in srgb, var(--_primary) 12%, var(--_line));
    border-radius: 999px;
    background: color-mix(in srgb, var(--_primary) 7%, #ffffff);
    color: color-mix(in srgb, var(--_ink) 76%, var(--_primary));
    font-size: 12px;
    font-weight: 900;
    line-height: 1.1;
    overflow: hidden;
    text-overflow: ellipsis;
}
.halmo-not__import-chip.is-empty {
    background: color-mix(in srgb, var(--_muted) 7%, #ffffff);
    color: color-mix(in srgb, var(--_muted) 82%, #ffffff);
}

.halmo-not__product-cell {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    max-width: 100%;
}
.halmo-not__product-link {
    display: inline-flex;
    max-width: 100%;
    color: inherit;
    font-weight: 900;
    text-decoration: none;
}
.halmo-not__product-link:hover,
.halmo-not__product-link:focus-visible {
    color: var(--_primary-dark);
    text-decoration: underline;
}
.halmo-not__product-link:focus-visible {
    outline: 2px solid color-mix(in srgb, var(--_primary) 55%, #ffffff);
    outline-offset: 3px;
    border-radius: 6px;
}
.halmo-not__product-link.is-plain { cursor: default; }
.halmo-not__product-text {
    overflow-wrap: anywhere;
}
.halmo-not__product-chart-btn {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 22px;
    height: 22px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: var(--_primary-soft);
    color: var(--_primary-dark);
    font-size: 12px;
    line-height: 1;
    cursor: pointer;
    opacity: 0;
    transform: translateX(-3px);
    transition: opacity .18s ease, transform .18s ease;
}
.halmo-not__product-cell:hover .halmo-not__product-chart-btn,
.halmo-not__product-cell:focus-within .halmo-not__product-chart-btn,
.halmo-not__product-chart-btn:focus-visible {
    opacity: 1;
    transform: translateX(0);
}
.halmo-not__product-chart-btn:focus-visible {
    outline: 2px solid color-mix(in srgb, var(--_primary) 55%, #ffffff);
    outline-offset: 3px;
}
.halmo-not__product-chart-btn[data-tip] {
    cursor: pointer;
}

/* Custom price-chart tooltip (replaces the native title bubble). Body-anchored
   so it escapes the table's overflow:auto and matches the premium palette. */
.halmo-not__tip {
    position: absolute;
    z-index: 2147483000;
    left: 0;
    top: 0;
    max-width: 280px;
    margin: 0;
    padding: 9px 13px;
    border-radius: 12px;
    background: var(--_ink-strong, #07152a);
    color: #f4f8fb;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.35;
    letter-spacing: .1px;
    text-align: center;
    box-shadow: 0 14px 34px rgba(7, 21, 42, .26), 0 2px 6px rgba(7, 21, 42, .18);
    pointer-events: none;
    opacity: 0;
    transform: translateY(-3px) scale(.97);
    transform-origin: center top;
    transition: opacity .14s ease, transform .14s ease;
}
.halmo-not__tip[data-place="above"] {
    transform-origin: center bottom;
    transform: translateY(3px) scale(.97);
}
.halmo-not__tip.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}
.halmo-not__tip::after {
    content: "";
    position: absolute;
    left: var(--halmo-tip-arrow, 50%);
    width: 11px;
    height: 11px;
    margin-left: -5.5px;
    background: var(--_ink-strong, #07152a);
    transform: rotate(45deg);
    border-radius: 2px;
}
.halmo-not__tip[data-place="below"]::after {
    top: -4px;
}
.halmo-not__tip[data-place="above"]::after {
    bottom: -4px;
}
@media (prefers-reduced-motion: reduce) {
    .halmo-not__tip { transition: opacity .14s ease; transform: none; }
    .halmo-not__tip[data-place="above"] { transform: none; }
    .halmo-not__tip.is-visible { transform: none; }
}

.halmo-not__trend {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 999px;
    color: var(--_muted);
    background: color-mix(in srgb, var(--_muted) 9%, #ffffff);
}
.halmo-not__trend-icon {
    display: block;
    width: 20px;
    height: 20px;
    overflow: visible;
}
.halmo-not__trend-icon path {
    fill: none;
    stroke: currentColor;
    stroke-width: 2.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.halmo-not__trend.is-up {
    color: var(--_primary-dark);
    background: color-mix(in srgb, var(--_primary) 12%, #ffffff);
}
.halmo-not__trend.is-down {
    color: var(--_danger);
    background: var(--_danger-soft);
}
.halmo-not__trend.is-flat,
.halmo-not__trend.is-none {
    color: var(--_muted);
    background: color-mix(in srgb, var(--_muted) 10%, #ffffff);
    font-weight: 900;
}

.halmo-not__trend-legend {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 11px;
    margin: 10px 0 0;
    padding: 10px 12px;
    border: 1px solid var(--_line);
    border-radius: 14px;
    background: var(--_surface-soft);
    color: var(--_muted);
    font-size: 13px;
}
.halmo-not__trend-legend[hidden] { display: none !important; }
.halmo-not__trend-legend .halmo-not__trend { width: 24px; height: 24px; font-size: 14px; }

.halmo-not__legend {
    margin: 10px 0 0;
    padding: 11px 13px;
    border: 1px solid color-mix(in srgb, var(--_line) 76%, #ffffff);
    border-radius: 14px;
    background: linear-gradient(180deg, #ffffff, #f8fafb);
    color: var(--_muted);
    font-size: 13px;
    line-height: 1.45;
}
.halmo-not__est-mark {
    font-weight: 900;
    color: var(--_accent);
}
.halmo-not__loading,
.halmo-not__empty,
.halmo-not__error,
.halmo-not__chart-empty {
    padding: 22px;
    color: var(--_muted);
    text-align: center;
}
.halmo-not__loading {
    border: 1px solid var(--_line);
    border-radius: 18px;
    background: linear-gradient(90deg, #ffffff 0%, #f6faf8 50%, #ffffff 100%);
    background-size: 220% 100%;
    animation: halmoNotShimmer 1.25s linear infinite;
}
.halmo-not__error { color: var(--_accent); }
.halmo-not__empty-state {
    border: 1px solid color-mix(in srgb, var(--_primary) 12%, var(--_line));
    border-radius: 22px;
    background:
        radial-gradient(circle at 50% -20%, color-mix(in srgb, var(--_primary) 10%, transparent), transparent 48%),
        var(--_surface);
    box-shadow: var(--_shadow-sm);
}
.halmo-not__empty-state p {
    margin: 0 0 12px;
    font-weight: 700;
}
.halmo-not__empty-note {
    margin: 8px 0 0 !important;
    font-size: 13px;
    color: var(--_muted);
}
.halmo-not__goto-date {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    border: 1px solid var(--_primary-dark);
    border-radius: 999px;
    background: linear-gradient(135deg, var(--_primary), var(--_primary-dark));
    color: #fff;
    padding: 9px 18px;
    font-size: 14px;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 10px 22px color-mix(in srgb, var(--_primary) 22%, transparent);
    transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}
.halmo-not__goto-date:hover,
.halmo-not__goto-date:focus-visible {
    color: #fff;
    outline: none;
    transform: translateY(-1px);
    filter: brightness(.98);
    box-shadow: 0 14px 28px color-mix(in srgb, var(--_primary) 28%, transparent);
}

/* Price-history modal. */
.halmo-not__modal[hidden] { display: none !important; }
.halmo-not__modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    overflow-y: auto;
    padding: 20px 18px;
}
.halmo-not__modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(7, 15, 27, .62);
    backdrop-filter: blur(5px);
}
.halmo-not__dialog {
    position: relative;
    z-index: 1;
    width: min(980px, 100%);
    max-height: calc(100vh - 40px);
    margin: auto 0;
    overflow: auto;
    background: linear-gradient(180deg, #ffffff, #fbfdfc);
    color: var(--_ink);
    border: 1px solid rgba(255, 255, 255, .5);
    border-radius: 24px;
    box-shadow: 0 30px 90px rgba(0, 0, 0, .28);
    padding: 24px;
}
.halmo-not__modal-title {
    margin: 0 48px 18px 0;
    font-family: var(--hm-font-head, inherit);
    font-size: clamp(20px, 2.4vw, 30px);
    font-weight: 900;
    line-height: 1.18;
    color: var(--_ink-strong);
}
.halmo-not__modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 38px;
    height: 38px;
    border: 1px solid var(--_line);
    border-radius: 999px;
    background: #ffffff;
    color: var(--_ink);
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 6px 16px rgba(15, 35, 52, .08);
}
.halmo-not__modal-close:hover,
.halmo-not__modal-close:focus-visible {
    border-color: var(--_primary);
    color: var(--_primary-dark);
    outline: none;
}
.halmo-not__modal-footer {
    margin-top: 14px;
    text-align: right;
}
.halmo-not__modal-fullcard {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--_primary-dark);
    font-weight: 800;
    font-size: 14px;
    text-decoration: none;
}
.halmo-not__modal-fullcard:hover,
.halmo-not__modal-fullcard:focus-visible {
    text-decoration: underline;
}
.halmo-not__modal-fullcard[hidden] { display: none; }
.halmo-not__modal-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 14px;
    align-items: center;
    margin-bottom: 16px;
    padding: 13px;
    border: 1px solid var(--_line);
    border-radius: 16px;
    background: var(--_surface-soft);
}
.halmo-not__modal-controls label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 14px;
    color: var(--_muted);
    font-weight: 800;
}
.halmo-not__range-panel {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 7px;
}
.halmo-not__range-label {
    margin-right: 2px;
    color: var(--_muted);
    font-size: 14px;
    font-weight: 900;
}
.halmo-not__range-btn[hidden] {
    /* 0.70.2: the base rule below sets display, which beats the browser
       default for [hidden] - without this the JS toggle has no effect. */
    display: none !important;
}
.halmo-not__range-btn {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    border: 1px solid color-mix(in srgb, var(--_line-strong) 88%, #ffffff);
    border-radius: 999px;
    background: #ffffff;
    color: var(--_ink);
    padding: 7px 12px;
    font-size: 13px;
    font-weight: 900;
    line-height: 1.1;
    white-space: nowrap;
    cursor: pointer;
    box-shadow: 0 5px 14px rgba(15, 35, 52, .05);
    transition: transform .18s ease, border-color .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease;
}
.halmo-not__range-btn:hover,
.halmo-not__range-btn:focus-visible {
    border-color: color-mix(in srgb, var(--_primary) 42%, var(--_line-strong));
    color: var(--_primary-dark);
    outline: none;
    transform: translateY(-1px);
}
.halmo-not__range-btn.is-active {
    border-color: var(--_primary-dark);
    background: linear-gradient(135deg, var(--_primary), var(--_primary-dark));
    color: #ffffff;
    box-shadow: 0 10px 24px color-mix(in srgb, var(--_primary) 22%, transparent);
}
.halmo-not__modal-controls select,
.halmo-not__modal-controls input {
    min-height: 38px;
    border: 1px solid var(--_line-strong);
    border-radius: 11px;
    background: #ffffff;
    color: var(--_ink);
    padding: 7px 10px;
    font-size: 14px;
    font-weight: 700;
}
.halmo-not__chart {
    position: relative;
    min-height: 230px;
}
.halmo-not__chart-tooltip {
    position: absolute;
    z-index: 3;
    left: 0;
    top: 0;
    max-width: min(240px, calc(100% - 16px));
    padding: 7px 10px;
    border-radius: 12px;
    background: rgba(7, 21, 42, .94);
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.3;
    box-shadow: 0 10px 28px rgba(7, 21, 42, .24);
    transform: translate(-50%, calc(-100% - 12px));
    pointer-events: none;
    white-space: nowrap;
}
.halmo-not__chart-tooltip::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -6px;
    width: 10px;
    height: 10px;
    background: rgba(7, 21, 42, .94);
    transform: translateX(-50%) rotate(45deg);
}
.halmo-not__chart-tooltip[hidden] { display: none !important; }
.halmo-not__chart-svg {
    display: block;
    width: 100%;
    height: auto;
    border: 1px solid var(--_line);
    border-radius: 18px;
    background: linear-gradient(180deg, #ffffff, #fbfdfc);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8);
}
.halmo-not__chart-grid { stroke: var(--_line); stroke-width: 1; }
.halmo-not__chart-axis-line { stroke: var(--_line-strong); stroke-width: 1.2; }
.halmo-not__chart-axis {
    fill: var(--_muted);
    font-size: 12px;
    font-family: var(--hm-font-base, inherit);
}
.halmo-not__chart-line {
    fill: none;
    stroke: var(--_primary);
    stroke-width: 3.2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.halmo-not__chart-dot {
    fill: #ffffff;
    stroke: var(--_primary);
    stroke-width: 2;
    transition: transform .14s ease, fill .14s ease, stroke-width .14s ease;
}
.halmo-not__chart-dot:hover,
.halmo-not__chart-dot:focus {
    fill: var(--_primary-soft);
    stroke-width: 2.6;
    outline: none;
}
.halmo-not__chart-summary {
    margin: 11px 0 0;
    color: var(--_muted);
    font-size: 13px;
    font-weight: 700;
}

@keyframes halmoNotShimmer {
    0% { background-position: 220% 0; }
    100% { background-position: -220% 0; }
}

@media (max-width: 760px) {
    .halmo-not__toolbar { padding: 12px; border-radius: 18px; }
    .halmo-not__search,
    .halmo-not__groupwrap,
    .halmo-not__datewrap { flex: 1 1 100%; width: 100%; }
    .halmo-not__groupwrap,
    .halmo-not__datewrap { justify-content: space-between; }
    .halmo-not__tabs { flex-wrap: nowrap; padding-bottom: 0; }
    .halmo-not__tab { flex: 0 0 auto; min-height: 45px; padding: 0 14px; }
    .halmo-not__table { min-width: 660px; }
    .halmo-not__table th,
    .halmo-not__table td { padding: 12px 13px; font-size: 14px; }
}

@media (max-width: 520px) {
    .halmo-not__meta { display: flex; border-radius: 14px; }
    .halmo-not__table { min-width: 560px; }
    .halmo-not__c-unit { display: none; }
    .halmo-not__table th.halmo-not__c-unit { display: none; }
    .halmo-not__c-name { width: 42%; }
    .halmo-not__c-price { width: 28%; }
    .halmo-not__c-avg { width: 30%; }
    .halmo-not__table th,
    .halmo-not__table td { padding: 11px 10px; font-size: 13px; }
    .halmo-not__avg-wrap { gap: 5px; padding-left: 8px; }
    .halmo-not__product-chart-btn { opacity: 1; transform: none; }
    .halmo-not__dialog { padding: 18px 14px; border-radius: 18px; }
    .halmo-not__modal-controls { align-items: stretch; }
    .halmo-not__modal-controls label { flex: 1 1 100%; justify-content: space-between; }
    .halmo-not__modal-controls select,
    .halmo-not__modal-controls input { flex: 0 0 auto; max-width: 170px; }
}

@media (prefers-reduced-motion: reduce) {
    .halmo-not__tab,
    .halmo-not__search,
    .halmo-not__goto-date,
    .halmo-not__range-btn,
    .halmo-not__product-chart-btn { transition: none; }
    .halmo-not__loading { animation: none; }
}

/* Kadence can style plain <button> elements very strongly. Keep the quotation
   UI controls readable in all states and preserve the premium tab design. */
.halmo-notowania .halmo-not__tabs .halmo-not__tab,
.halmo-notowania button.halmo-not__tab {
    appearance: none !important;
    display: inline-flex !important;
    background: transparent !important;
    color: var(--_muted) !important;
    border: 1px solid transparent !important;
    border-bottom: 0 !important;
    border-radius: 13px 13px 0 0 !important;
    box-shadow: none !important;
    text-decoration: none !important;
    text-transform: none !important;
    letter-spacing: normal !important;
}
.halmo-notowania .halmo-not__tabs .halmo-not__tab:hover,
.halmo-notowania .halmo-not__tabs .halmo-not__tab:focus,
.halmo-notowania button.halmo-not__tab:hover,
.halmo-notowania button.halmo-not__tab:focus {
    background: color-mix(in srgb, var(--_primary) 5%, #ffffff) !important;
    color: var(--_ink-strong) !important;
}
.halmo-notowania .halmo-not__tabs .halmo-not__tab.is-active,
.halmo-notowania .halmo-not__tabs .halmo-not__tab.is-active:hover,
.halmo-notowania .halmo-not__tabs .halmo-not__tab.is-active:focus,
.halmo-notowania button.halmo-not__tab.is-active,
.halmo-notowania button.halmo-not__tab.is-active:hover,
.halmo-notowania button.halmo-not__tab.is-active:focus {
    background: #ffffff !important;
    color: var(--_primary-dark) !important;
    border-color: var(--_line-strong) !important;
    border-bottom: 0 !important;
    box-shadow: 0 -8px 22px rgba(15, 35, 52, .06) !important;
}
.halmo-notowania button.halmo-not__product-chart-btn {
    background: var(--_primary-soft) !important;
    color: var(--_primary-dark) !important;
    border: 0 !important;
    box-shadow: none !important;
    text-transform: none !important;
    letter-spacing: normal !important;
}
.halmo-notowania button.halmo-not__product-chart-btn:hover,
.halmo-notowania button.halmo-not__product-chart-btn:focus {
    background: var(--_primary-soft) !important;
    color: var(--_primary-dark) !important;
}
.halmo-notowania a.halmo-not__product-link {
    text-decoration: none !important;
    text-transform: none !important;
}
.halmo-notowania a.halmo-not__product-link:hover,
.halmo-notowania a.halmo-not__product-link:focus {
    color: var(--_primary-dark) !important;
    text-decoration: underline !important;
}
.halmo-notowania button.halmo-not__goto-date,
.halmo-notowania button.halmo-not__goto-date:hover,
.halmo-notowania button.halmo-not__goto-date:focus {
    background: linear-gradient(135deg, var(--_primary), var(--_primary-dark)) !important;
    color: #fff !important;
    border-color: var(--_primary-dark) !important;
}
.halmo-notowania button.halmo-not__modal-close {
    background: #ffffff !important;
    color: var(--_ink) !important;
    border-color: var(--_line) !important;
    box-shadow: 0 6px 16px rgba(15, 35, 52, .08) !important;
}
.halmo-notowania button.halmo-not__modal-close:hover,
.halmo-notowania button.halmo-not__modal-close:focus {
    color: var(--_primary-dark) !important;
    border-color: var(--_primary) !important;
}

.halmo-notowania button.halmo-not__range-btn {
    background: #ffffff !important;
    color: var(--_ink) !important;
    border-color: color-mix(in srgb, var(--_line-strong) 88%, #ffffff) !important;
    box-shadow: 0 5px 14px rgba(15, 35, 52, .05) !important;
    text-transform: none !important;
    letter-spacing: normal !important;
}
.halmo-notowania button.halmo-not__range-btn:hover,
.halmo-notowania button.halmo-not__range-btn:focus {
    background: #ffffff !important;
    color: var(--_primary-dark) !important;
    border-color: color-mix(in srgb, var(--_primary) 42%, var(--_line-strong)) !important;
}
.halmo-notowania button.halmo-not__range-btn.is-active,
.halmo-notowania button.halmo-not__range-btn.is-active:hover,
.halmo-notowania button.halmo-not__range-btn.is-active:focus {
    background: linear-gradient(135deg, var(--_primary), var(--_primary-dark)) !important;
    color: #ffffff !important;
    border-color: var(--_primary-dark) !important;
    box-shadow: 0 10px 24px color-mix(in srgb, var(--_primary) 22%, transparent) !important;
}


/* Mobile polish for quotation tabs, price rows and chart modal. */
.halmo-not__product-chart-svg,
.halmo-not__modal-close-svg {
    display: block;
    width: 100%;
    height: 100%;
    overflow: visible;
}
.halmo-not__product-chart-svg path,
.halmo-not__product-chart-svg circle,
.halmo-not__modal-close-svg path {
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.halmo-not__product-chart-svg path,
.halmo-not__product-chart-svg circle { stroke-width: 2; }
.halmo-not__modal-close-svg path { stroke-width: 2.5; }
.halmo-notowania button.halmo-not__modal-close {
    position: absolute !important;
    top: 18px !important;
    right: 18px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 42px !important;
    height: 42px !important;
    min-width: 0 !important;
    min-height: 0 !important;
    padding: 0 !important;
    border-radius: 999px !important;
    font-size: 0 !important;
    line-height: 1 !important;
}
.halmo-notowania button.halmo-not__modal-close svg {
    width: 20px !important;
    height: 20px !important;
    pointer-events: none;
}

@media (max-width: 760px) {
    .halmo-notowania {
        max-width: 100%;
    }
    .halmo-not__tabs {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 6px !important;
        align-items: stretch !important;
        margin-bottom: 18px !important;
        padding: 5px !important;
        overflow: visible !important;
        border: 1px solid color-mix(in srgb, var(--_line) 86%, #ffffff) !important;
        border-radius: 18px !important;
        background: linear-gradient(180deg, #ffffff, #f7faf9) !important;
        box-shadow: 0 10px 26px rgba(15, 35, 52, .06) !important;
    }
    .halmo-notowania .halmo-not__tabs .halmo-not__tab,
    .halmo-notowania button.halmo-not__tab {
        flex: 1 1 calc(50% - 6px) !important;
        min-width: 0 !important;
        min-height: 42px !important;
        max-width: 100% !important;
        justify-content: space-between !important;
        gap: 7px !important;
        padding: 0 10px !important;
        border: 1px solid transparent !important;
        border-radius: 13px !important;
        background: transparent !important;
        box-shadow: none !important;
    }
    .halmo-not__tab::after {
        left: 10px;
        right: 10px;
        bottom: 4px;
        height: 2px;
        border-radius: 999px;
    }
    .halmo-not__tab-label {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    .halmo-not__tab-count {
        flex: 0 0 auto;
        min-width: 27px;
        height: 24px;
        padding-inline: 7px;
    }
    .halmo-notowania .halmo-not__tabs .halmo-not__tab.is-active,
    .halmo-notowania .halmo-not__tabs .halmo-not__tab.is-active:hover,
    .halmo-notowania .halmo-not__tabs .halmo-not__tab.is-active:focus,
    .halmo-notowania button.halmo-not__tab.is-active,
    .halmo-notowania button.halmo-not__tab.is-active:hover,
    .halmo-notowania button.halmo-not__tab.is-active:focus {
        background: #ffffff !important;
        border-color: color-mix(in srgb, var(--_primary) 22%, var(--_line)) !important;
        border-bottom: 1px solid color-mix(in srgb, var(--_primary) 22%, var(--_line)) !important;
        box-shadow: 0 8px 20px rgba(15, 35, 52, .08) !important;
    }
    .halmo-not__table {
        min-width: 0 !important;
        width: 100% !important;
        table-layout: fixed;
    }
    .halmo-not__table-wrap {
        overflow-x: hidden;
    }
}

@media (max-width: 560px) {
    .halmo-not__section { margin-bottom: 20px; }
    .halmo-not__section-head { margin-bottom: 9px; }
    .halmo-not__table-wrap {
        overflow: hidden;
        border-radius: 18px;
        background: linear-gradient(180deg, #ffffff, #fbfdfc);
    }
    .halmo-not__table {
        min-width: 0 !important;
        width: 100%;
    }
    .halmo-not__table,
    .halmo-not__table thead,
    .halmo-not__table tbody,
    .halmo-not__table tr,
    .halmo-not__table th,
    .halmo-not__table td {
        display: block;
    }
    .halmo-not__table thead { display: none; }
    .halmo-not__table tbody tr.halmo-not__row {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        grid-template-areas:
            "name avg"
            "unit avg"
            "import avg"
            "price avg";
        gap: 7px 12px;
        align-items: center;
        padding: 14px 14px;
        border-bottom: 1px solid color-mix(in srgb, var(--_line) 78%, #ffffff);
        background: #ffffff;
    }
    .halmo-not__table tbody tr:nth-child(even) td,
    .halmo-not__table tbody tr:hover td {
        background: transparent;
    }
    .halmo-not__table tbody tr:nth-child(even) {
        background: color-mix(in srgb, var(--_surface-soft) 58%, #ffffff);
    }
    .halmo-not__table tbody tr:last-child { border-bottom: 0; }
    .halmo-not__table th,
    .halmo-not__table td {
        width: auto !important;
        padding: 0 !important;
        border: 0 !important;
        min-width: 0;
    }
    .halmo-not__c-unit {
        display: block !important;
        grid-area: unit;
        color: var(--_muted);
        font-size: 12px !important;
        font-weight: 800;
        line-height: 1.25;
        white-space: normal;
    }
    .halmo-not__c-unit::before {
        content: "Opakowanie: ";
        color: color-mix(in srgb, var(--_muted) 76%, #ffffff);
        font-size: 10px;
        font-weight: 900;
        letter-spacing: .06em;
        text-transform: uppercase;
    }
    .halmo-not__c-import {
        display: block !important;
        grid-area: import;
        font-size: 12px !important;
        white-space: normal;
    }
    .halmo-not__c-import::before {
        content: "Grupa importu: ";
        color: color-mix(in srgb, var(--_muted) 76%, #ffffff);
        font-size: 10px;
        font-weight: 900;
        letter-spacing: .06em;
        text-transform: uppercase;
    }
    .halmo-not__import-chip {
        min-height: 24px;
        padding: 3px 8px;
        font-size: 11px;
    }
    .halmo-not__c-name { grid-area: name; }
    .halmo-not__c-price {
        grid-area: price;
        color: var(--_muted);
        font-size: 13px !important;
        font-weight: 800;
        white-space: normal;
    }
    .halmo-not__c-price::before {
        content: "Cena: ";
        color: color-mix(in srgb, var(--_muted) 76%, #ffffff);
        font-size: 10px;
        font-weight: 900;
        letter-spacing: .06em;
        text-transform: uppercase;
    }
    .halmo-not__c-avg {
        grid-area: avg;
        align-self: center;
        justify-self: end;
        text-align: right;
        white-space: nowrap;
    }
    .halmo-not__c-avg::before {
        content: "Średnia";
        display: block;
        margin: 0 0 4px;
        color: color-mix(in srgb, var(--_muted) 72%, #ffffff);
        font-size: 10px;
        font-weight: 900;
        letter-spacing: .06em;
        line-height: 1;
        text-transform: uppercase;
    }
    .halmo-not__product-cell {
        width: 100%;
        gap: 7px;
        font-size: 15px;
        line-height: 1.18;
    }
    .halmo-not__product-text {
        min-width: 0;
        overflow-wrap: anywhere;
        hyphens: auto;
    }
    .halmo-not__product-chart-btn {
        width: 24px;
        height: 24px;
        opacity: 1;
        transform: none;
        background: linear-gradient(180deg, #ffffff, var(--_primary-soft));
        color: var(--_primary-dark);
        border: 1px solid color-mix(in srgb, var(--_primary) 14%, var(--_line));
        box-shadow: 0 5px 12px rgba(15, 35, 52, .06);
    }
    .halmo-not__avg-wrap {
        min-height: 32px;
        gap: 6px;
        padding: 4px 5px 4px 9px;
    }
    .halmo-not__avg-value { font-size: 13px; }
    .halmo-not__c-avg .halmo-not__trend {
        width: 25px;
        height: 25px;
    }
    .halmo-not__c-avg .halmo-not__trend-icon {
        width: 16px;
        height: 16px;
    }
    .halmo-not__modal {
        padding: 10px;
        align-items: flex-start;
    }
    .halmo-not__dialog {
        width: 100%;
        max-height: calc(100dvh - 20px);
        padding: 18px 14px 16px;
        border-radius: 22px;
    }
    .halmo-not__modal-title {
        margin: 2px 54px 16px 0;
        font-size: clamp(22px, 7vw, 28px);
        line-height: 1.12;
    }
    .halmo-notowania button.halmo-not__modal-close {
        top: 14px !important;
        right: 14px !important;
        width: 40px !important;
        height: 40px !important;
    }
    .halmo-not__modal-controls {
        display: grid;
        grid-template-columns: 1fr;
        gap: 8px;
        padding: 10px;
        border-radius: 16px;
    }
    .halmo-not__range-panel {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 6px;
        width: 100%;
    }
    .halmo-not__range-label {
        grid-column: 1 / -1;
        margin: 0 0 2px;
        font-size: 13px;
    }
    .halmo-not__range-btn {
        width: 100%;
        min-height: 36px;
        padding: 6px 10px;
        font-size: 12px;
        line-height: 1.15;
        white-space: normal;
        box-shadow: 0 4px 10px rgba(15, 35, 52, .04);
    }
    /* Four range buttons use a compact 2x2 grid on mobile. */
    .halmo-not__modal-controls label {
        display: grid;
        grid-template-columns: 76px minmax(0, 1fr);
        gap: 10px;
        align-items: center;
        width: 100%;
        justify-content: normal;
    }
    .halmo-not__modal-controls select,
    .halmo-not__modal-controls input {
        width: 100%;
        max-width: none;
        min-width: 0;
    }
    .halmo-not__chart { min-height: 190px; }
    .halmo-not__chart-summary {
        font-size: 12px;
        line-height: 1.35;
    }
    .halmo-not__chart-tooltip {
        max-width: calc(100% - 12px);
        white-space: normal;
        font-size: 11px;
        padding: 6px 8px;
    }
}

@media (max-width: 380px) {
    .halmo-not__range-panel {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 6px;
    }
    .halmo-not__range-label { grid-column: 1 / -1; }
    .halmo-not__range-btn {
        min-height: 34px;
        padding: 5px 8px;
        font-size: 11px;
    }
    /* Four range buttons use a compact 2x2 grid on narrow mobile. */
    .halmo-notowania .halmo-not__tabs .halmo-not__tab,
    .halmo-notowania button.halmo-not__tab {
        flex-basis: 100% !important;
    }
    .halmo-not__table tbody tr.halmo-not__row {
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas:
            "name"
            "unit"
            "import"
            "price"
            "avg";
    }
    .halmo-not__c-avg {
        justify-self: start;
        text-align: left;
    }
    .halmo-not__c-avg::before { display: none; }
}

/* Search fallback: product absent from current bulletin, but present historically. */
.halmo-not__last-seen {
    text-align: left;
}
.halmo-not__last-list {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}
.halmo-not__last-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border: 1px solid color-mix(in srgb, var(--_line) 78%, #ffffff);
    border-radius: 16px;
    background: linear-gradient(180deg, #ffffff, #f8fafb);
}
.halmo-not__last-main {
    display: grid;
    gap: 4px;
    min-width: 0;
}
.halmo-not__last-main strong {
    color: var(--_ink-strong);
    font-size: 15px;
}
.halmo-not__last-main span,
.halmo-not__last-price span {
    color: var(--_muted);
    font-size: 12px;
    font-weight: 700;
}
.halmo-not__last-price {
    display: grid;
    gap: 4px;
    text-align: right;
    white-space: nowrap;
}
.halmo-not__last-price strong {
    color: var(--_primary-dark);
    font-size: 15px;
}
@media (max-width: 720px) {
    .halmo-not__last-item {
        grid-template-columns: 1fr;
        align-items: stretch;
    }
    .halmo-not__last-price {
        text-align: left;
    }
}
