/* ==========================================================================
   Shared components for every page except home and product: breadcrumbs,
   page head, glass cards, fields (house form structure), alerts, empty
   states, chips, rows, pager. Tokens from main.css only.
   ========================================================================== */

body.vz-surface { background: var(--surface); }

.vz-page { padding-top: 16px; padding-bottom: clamp(48px, 6vw, 80px); }
.vz-ink { color: var(--ink); }
.vz-muted { color: var(--muted); }
.vz-right { text-align: right; }

/* ---------- breadcrumbs (same as product page) ---------- */

.vz-crumbs ol { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; min-height: 36px; font-size: 13px; color: var(--muted); }
.vz-crumbs li { display: flex; align-items: center; gap: 6px; }
.vz-crumbs li + li::before { content: "›"; color: var(--faint); }
.vz-crumbs a { color: var(--muted); }
.vz-crumbs a:hover { color: var(--ink); }
.vz-crumbs [aria-current] { color: var(--ink); font-weight: 500; }
@media (max-width: 899px) {
    .vz-crumbs a { display: inline-flex; align-items: center; min-height: 44px; }
}

/* ---------- page head ---------- */

.vz-h1 {
    margin-top: 12px;
    font-family: var(--font-head);
    font-weight: 600;
    font-size: clamp(26px, 3.4vw, 36px);
    letter-spacing: -.02em;
    line-height: 1.2;
    overflow-wrap: anywhere;
    text-wrap: balance;
}
.vz-lead { margin-top: 8px; font-size: 16px; color: var(--muted); max-width: 720px; text-wrap: pretty; }
.vz-h3 { font-family: var(--font-head); font-weight: 600; font-size: 17px; line-height: 1.3; }

/* ---------- cards ---------- */

.vz-glass {
    border-radius: var(--r-card);
    background: rgba(255, 255, 255, .86);
    -webkit-backdrop-filter: var(--blur);
    backdrop-filter: var(--blur);
    box-shadow: inset 0 0 0 1px var(--line);
    padding: clamp(18px, 3vw, 28px);
}
.vz-glass:focus { outline: none; }
.vz-panel { border-radius: var(--r-card); background: var(--white); box-shadow: inset 0 0 0 1px var(--line); }
.vz-inner { border-radius: var(--r-inner); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); padding: 14px 16px; }

.vz-cardhead { display: flex; gap: 14px; align-items: flex-start; }
.vz-cardhead__text { margin-top: 4px; font-size: 14.5px; color: var(--muted); }

.vz-tile--36 { width: 36px; height: 36px; }
.vz-tile--56 { width: 56px; height: 56px; }
.vz-tile--ok { background: var(--ok-bg); color: var(--ok); }
.vz-tile--mono { font-family: var(--font-mono); font-weight: 600; font-size: 14px; }

/* tone text */
.vz-tone--ok { color: var(--ok); }
.vz-tone--accent { color: var(--tone-accent); }
.vz-tone--blue { color: var(--blue); }
.vz-tone--warn { color: var(--warn); }
.vz-tone--bad { color: var(--bad); }
.vz-tone--gray { color: var(--gray); }

/* ---------- buttons (additions) ---------- */

.vz-btn--ghost { background: transparent; color: var(--ink); }
.vz-btn--ghost:hover { background: var(--hover); color: var(--ink); }
.vz-btn--block { width: 100%; }
.vz-btn[disabled], .vz-btn.is-busy { opacity: .7; cursor: default; }
.vz-textbtn {
    height: 36px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--accent-text);
    font-weight: 600;
    font-size: 14px;
}
.vz-textbtn:hover { text-decoration: underline; }
.vz-textbtn[hidden] { display: none; }

/* ---------- small search-in-list field ---------- */

.vz-minisearch {
    height: 36px;
    border-radius: var(--r-ctl);
    background: var(--white);
    box-shadow: inset 0 0 0 1px var(--ring-input);
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 12px;
    margin: 4px 0;
    color: var(--muted);
}
.vz-minisearch[hidden] { display: none; }
.vz-minisearch:focus-within { box-shadow: inset 0 0 0 2px var(--accent); }
.vz-minisearch input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 14px; color: var(--ink); }

/* ---------- chips ---------- */

.vz-chip {
    flex: none;
    height: 36px;
    padding: 0 14px;
    border-radius: var(--r-pill);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--ink);
    background: var(--white);
    box-shadow: inset 0 0 0 1px var(--ring-soft);
    text-decoration: none;
}
.vz-chip:hover { background: var(--hover); color: var(--ink); text-decoration: none; }
.vz-chip[aria-current] { background: var(--accent-tint); box-shadow: var(--accent-tint-ring); color: var(--accent-text); }
.vz-chip__n { font-size: 12px; color: var(--muted); }
.vz-chip--on {
    height: 32px;
    padding: 0 10px 0 12px;
    gap: 6px;
    font-size: 13.5px;
    font-weight: 600;
    background: var(--accent-tint);
    box-shadow: var(--accent-tint-ring);
    color: var(--accent-text);
}
.vz-chip--on:hover { background: var(--accent-tint-hover); color: var(--accent-text); }
.vz-chip--ghost { height: 32px; padding: 0 10px; font-size: 13.5px; font-weight: 600; background: transparent; box-shadow: none; }
.vz-chip--ghost:hover { background: var(--hover); }

/* ---------- forms: label 13/500 above, field 44px r12, hint 12.5 below ---------- */

.vz-formgrid { margin-top: 20px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
@media (min-width: 640px) {
    .vz-formgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.vz-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.vz-field--full { grid-column: 1 / -1; }
.vz-field > label,
.vz-field__label {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-2);
    display: flex;
    align-items: center;
    gap: 6px;
}
.vz-req { color: var(--bad); }
.vz-opt { font-weight: 400; color: var(--muted); }
.vz-input,
.vz-select,
.vz-textarea {
    width: 100%;
    height: var(--h-ctl);
    border: 0;
    border-radius: var(--r-ctl);
    background: var(--white);
    box-shadow: inset 0 0 0 1px var(--ring-input);
    padding: 0 14px;
    font-size: 16px;
    color: var(--ink);
    appearance: none;
    -webkit-appearance: none;
}
.vz-textarea { height: auto; min-height: 120px; padding: 12px 14px; line-height: 1.5; resize: vertical; }
.vz-select {
    padding-right: 40px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235B6475' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
}
.vz-input:focus, .vz-select:focus, .vz-textarea:focus { outline: none; box-shadow: inset 0 0 0 2px var(--accent); }
.vz-input[aria-invalid="true"], .vz-select[aria-invalid="true"], .vz-textarea[aria-invalid="true"] { box-shadow: inset 0 0 0 2px var(--bad); }
.vz-input.vz-mono { font-family: var(--font-mono); }
input[type="number"].vz-input { -moz-appearance: textfield; }
@media (max-width: 639px) {
    .vz-input, .vz-select { height: 48px; }
}
.vz-hint { font-size: 12.5px; color: var(--muted); }
.vz-hint a, .vz-done__text a:not(.vz-link) { text-decoration: underline; }
.vz-field__err { display: flex; align-items: flex-start; gap: 6px; font-size: 12.5px; font-weight: 500; color: var(--bad); }
.vz-field__err .vz-icon { margin-top: 2px; }
.vz-formactions { margin-top: 20px; display: flex; align-items: center; flex-wrap: wrap; gap: 12px 16px; }
.vz-fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.vz-fieldset + .vz-fieldset { margin-top: 24px; padding-top: 24px; border-top: 1px solid var(--line); }
.vz-legend { padding: 0; font-family: var(--font-head); font-weight: 600; font-size: 15px; }

.vz-checkrow { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; padding-top: 12px; font-size: 14.5px; cursor: pointer; }
.vz-checkrow input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--accent); flex: none; }

/* phone: dial code + number */
.vz-phone { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 8px; }

/* honeypot */
.vz-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- alerts ---------- */

.vz-alert {
    margin-top: 16px;
    border-radius: var(--r-ctl);
    padding: 12px 14px;
    display: flex;
    gap: 10px;
    font-size: 14px;
    background: var(--c-bg);
    color: var(--c);
}
.vz-alert:focus { outline: 2px solid var(--c); outline-offset: 2px; }
.vz-alert > .vz-icon { flex: none; margin-top: 1px; }
.vz-alert p + p, .vz-alert p + ul { margin-top: 4px; }
.vz-alert ul { list-style: disc; padding-left: 18px; }
.vz-alert a { color: inherit; text-decoration: underline; font-weight: 600; }
.vz-alert--bad { --c: var(--bad); --c-bg: var(--bad-bg); }
.vz-alert--warn { --c: var(--warn); --c-bg: var(--warn-bg); }
.vz-alert--ok { --c: var(--ok); --c-bg: var(--ok-bg); }
.vz-alert--info { --c: var(--info-text); --c-bg: var(--info-bg); }
.vz-alert__body { flex: 1; min-width: 0; }
.vz-alert__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }

/* ---------- success card ---------- */

.vz-done { display: flex; gap: 14px; align-items: flex-start; }
.vz-done__text { margin-top: 4px; font-size: 14.5px; color: var(--text-2); }

/* ---------- empty state ---------- */

.vz-empty {
    margin-top: 16px;
    border-radius: var(--r-card);
    background: var(--white);
    box-shadow: inset 0 0 0 1px var(--line);
    padding: 32px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
}
.vz-empty__tile { width: 56px; height: 56px; }
.vz-empty__title { margin-top: 4px; font-family: var(--font-head); font-weight: 600; font-size: 17px; }
.vz-empty__text { font-size: 14.5px; color: var(--muted); max-width: 440px; }
.vz-empty__actions { margin-top: 8px; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }

/* ---------- compact rows (similar parts, recent orders) ---------- */

.vz-rows { border-radius: var(--r-card); background: var(--white); box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; }
.vz-rows li + li { border-top: 1px solid var(--line); }
.vz-rows__item { display: flex; align-items: center; gap: 12px; padding: 12px 16px; min-height: 56px; color: var(--ink); text-decoration: none; }
.vz-rows__item:hover { background: var(--hover-soft); color: var(--ink); text-decoration: none; }
.vz-rows__main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.vz-rows__mpn { font-size: 14.5px; font-weight: 600; overflow-wrap: anywhere; }
.vz-rows__title { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vz-rows__price { flex: none; font-size: 14.5px; font-weight: 600; }

/* category tiles (no results, 404) */
.vz-cattiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.vz-cattile {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    min-height: 56px;
    border-radius: var(--r-tile);
    background: var(--white);
    box-shadow: inset 0 0 0 1px var(--line);
    color: var(--ink);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.3;
    text-decoration: none;
}
.vz-cattile:hover { box-shadow: inset 0 0 0 1px rgba(10, 10, 10, .45); color: var(--ink); text-decoration: none; }

/* ---------- steps (How it works / What happens next) ---------- */

.vz-steps { display: flex; flex-direction: column; gap: 14px; counter-reset: step; }
.vz-steps li { display: flex; gap: 12px; align-items: flex-start; }
.vz-steps__n {
    flex: none;
    width: 32px;
    height: 32px;
    border-radius: var(--r-item);
    display: grid;
    place-items: center;
    background: var(--tint-yellow);
    color: var(--accent-text);
    font-family: var(--font-mono);
    font-size: 13px;
    font-weight: 600;
}
.vz-steps__title { font-weight: 600; font-size: 15px; }
.vz-steps__text { font-size: 14px; color: var(--muted); }

.vz-ticks { display: flex; flex-direction: column; gap: 8px; font-size: 14.5px; }
.vz-ticks li { display: flex; gap: 8px; align-items: flex-start; }
.vz-ticks .vz-icon { margin-top: 3px; color: var(--ok); }

/* ---------- key-value rows ---------- */

.vz-kvlist { margin: 0; }
.vz-kvlist > div { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.vz-kvlist > div:last-child { border-bottom: 0; }
.vz-kvlist dt { color: var(--muted); }
.vz-kvlist dd { margin: 0; text-align: right; overflow-wrap: anywhere; }

/* ---------- info note ---------- */

.vz-note {
    border-radius: var(--r-ctl);
    background: var(--info-bg);
    padding: 12px 14px;
    display: flex;
    gap: 10px;
    font-size: 14px;
    color: var(--info-text);
}
.vz-note .vz-icon { flex: none; margin-top: 2px; }

/* ---------- toast ---------- */

.vz-toast {
    position: fixed;
    left: 50%;
    bottom: 24px;
    transform: translateX(-50%);
    z-index: 100;
    background: var(--ink);
    color: var(--surface);
    border-radius: var(--r-pill);
    padding: 12px 20px;
    font-size: 14px;
    box-shadow: 0 20px 50px -20px rgba(10, 10, 10, .6);
    max-width: calc(100vw - 32px);
}
.vz-toast[hidden] { display: none; }

/* ---------- CTA card at page end ---------- */

.vz-cta {
    margin-top: clamp(32px, 5vw, 48px);
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px 20px;
    border-radius: var(--r-card);
    background: var(--white);
    box-shadow: inset 0 0 0 1px var(--line);
    padding: 20px 24px;
}
.vz-cta__body { flex: 1; min-width: min(100%, 240px); }
.vz-cta__text { margin-top: 2px; font-size: 14.5px; color: var(--muted); }
