/* Strausz Gumi cart and checkout */
.shop-card,
.shop-add,
.shop-empty,
.shop-summary,
.account-nav {
  --tire-navy: var(--sg-navy, #111827);
  --tire-orange: var(--sg-orange, #f59e0b);
  --tire-line: var(--sg-line, #e5e7eb);
  --tire-muted: var(--sg-muted, #6b7280);
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- header counters and pills ---------- */
.site-cart,
.site-compare { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; }
.site-cart { padding: 5px 8px 5px 14px; border-radius: 999px; background: var(--sg-brand-soft, #1f2937); }
.site-language {
  padding: 5px 14px; border-radius: 999px; background: var(--sg-brand-soft, #1f2937);
  color: var(--sg-on-brand-muted, #e5e7eb); font-size: 13px; font-weight: 700; text-decoration: none;
}
.site-language:hover { color: var(--sg-orange); }
.site-cart-count {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px;
  background: var(--sg-orange); color: var(--sg-on-accent, #111827); font-size: 12px;
}

/* ---------- add to cart ---------- */
.shop-add { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 16px 0; }
.shop-add-compact { margin: 0; gap: 6px; }
/* the label holds the caption, the field and the unit in one row; the field carries the box */
.shop-quantity { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; }
.shop-quantity input {
  width: 72px; min-height: 44px; padding: 0 8px; box-sizing: border-box;
  border: 1px solid var(--tire-line); border-radius: 12px; font: inherit; text-align: center;
}
.shop-add-compact .shop-quantity input { width: 60px; }

/* ---------- common ---------- */
.shop-card { padding: 24px; border: 1px solid var(--sg-line); border-radius: var(--sg-radius); background: var(--sg-card, #fff); }
.shop-card h2 { margin: 0 0 16px; font-size: 20px; }
.shop-alert { padding: 12px 16px; border-radius: 12px; margin: 0 0 20px; font-weight: 600; }
.shop-alert ul { margin: 0; padding-left: 20px; }
.shop-alert-ok { background: var(--sg-ok-bg, #dcfce7); color: var(--sg-ok-text, #166534); }
.shop-alert-error { background: var(--sg-error-bg, #fee2e2); color: var(--sg-error-text, #991b1b); }
.shop-alert-info { background: var(--sg-info-bg, #e0ecff); color: var(--sg-info-text, #1e3a8a); }
.account-confirm p { margin: 0 0 10px; }
.account-confirm form { margin: 0; }
.shop-note, .shop-small { color: var(--sg-muted); font-size: 14px; }
.shop-lead { font-size: 17px; }
.shop-mono { font-family: ui-monospace, Consolas, monospace; }
.shop-empty { text-align: center; }
.shop-empty p { font-size: 18px; }
.shop-link-button { padding: 0; border: 0; background: none; color: var(--sg-muted); font: inherit; font-size: 14px; text-decoration: underline; cursor: pointer; }
.shop-link-button:hover { color: var(--sg-error-text, #991b1b); }

.shop-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 24px; align-items: start; }
.shop-summary { position: sticky; top: 16px; display: flex; flex-direction: column; gap: 12px; }
.shop-summary h2 { margin-bottom: 4px; }
.shop-summary dl { display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; margin: 0; }
.shop-summary dt { color: var(--sg-muted); }
.shop-summary dd { margin: 0; font-weight: 700; text-align: right; }
.shop-continue { text-align: center; font-size: 14px; }

/* ---------- cart lines ---------- */
.shop-lines { list-style: none; margin: 0; padding: 0; }
.shop-line {
  display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto; align-items: center; gap: 12px 20px;
  padding: 16px 0; border-bottom: 1px solid var(--sg-line);
}
.shop-line:first-child { padding-top: 0; }
.shop-line:last-child { border-bottom: 0; padding-bottom: 0; }
.shop-line-info { display: flex; flex-direction: column; gap: 4px; }
.shop-line-info > a, .shop-line-info > span { font-weight: 700; color: var(--sg-text, #111827); }
.shop-line-info small { color: var(--sg-muted); }
.shop-line-quantity { display: flex; align-items: center; gap: 8px; }
.shop-line-quantity input {
  width: 64px; min-height: 40px; padding: 0 8px; box-sizing: border-box;
  border: 1px solid var(--sg-line); border-radius: 10px; font: inherit; text-align: center;
}
.shop-small.tire-button { min-height: 40px; padding: 0 14px; }
.shop-line-total { min-width: 110px; text-align: right; font-size: 17px; }
.shop-line-unavailable .shop-line-info, .shop-line-unavailable .shop-line-total { opacity: .55; }
.shop-line-unavailable .shop-line-total { text-decoration: line-through; }

/* ---------- checkout ---------- */
.shop-checkout { display: flex; flex-direction: column; gap: 20px; }
.shop-form { margin: 0; display: flex; flex-direction: column; gap: 14px; }
.shop-form legend { float: left; width: 100%; margin-bottom: 4px; padding: 0; font-size: 20px; font-weight: 800; }
.shop-field { display: flex; flex-direction: column; gap: 6px; }
.shop-field-row > .shop-field { flex: 1 1 200px; }
.shop-field > span { font-size: 14px; font-weight: 700; }
.shop-field input, .shop-field textarea, .shop-field select {
  width: 100%; min-height: 46px; padding: 10px 14px; box-sizing: border-box;
  border: 1px solid var(--sg-line); border-radius: 12px; font: inherit; background: var(--sg-card, #fff);
}
.shop-field textarea { resize: vertical; }
.shop-field input:focus, .shop-field textarea:focus, .shop-field select:focus { outline: 2px solid var(--sg-orange); outline-offset: 1px; border-color: transparent; }
.shop-field input.invalid, .shop-field textarea.invalid, .shop-field select.invalid { border-color: var(--sg-error-strong, #dc2626); }
.shop-field-row { display: flex; flex-wrap: wrap; gap: 14px; }
.shop-field-short { flex: 0 1 140px; }
.shop-checkout .validation-message, .shop-summary .validation-message { color: var(--sg-error-message, #b91c1c); font-size: 13px; font-weight: 600; }
.shop-company summary { cursor: pointer; font-weight: 700; margin-bottom: 12px; }
.shop-option {
  display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px;
  border: 1px solid var(--sg-line); border-radius: 14px; cursor: pointer;
}
.shop-option:has(input:checked) { border-color: var(--sg-orange); background: var(--sg-selected-bg, #fffbeb); }
.shop-option input { margin-top: 4px; accent-color: var(--sg-orange); }
.shop-summary-lines { list-style: none; margin: 0; padding: 0 0 12px; border-bottom: 1px solid var(--sg-line); font-size: 14px; }
.shop-summary-lines li { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; }
.shop-summary-lines li span:last-child { white-space: nowrap; }
.shop-summary-lines del { color: var(--sg-muted); font-weight: 400; }
.shop-discount-name { color: var(--sg-ok-text, #166534); }
.shop-coupon { display: flex; align-items: flex-end; gap: 8px; margin: 12px 0 4px; }
.shop-coupon .shop-field { flex: 1; margin: 0; }
.shop-terms { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; }
.shop-terms input { margin-top: 3px; accent-color: var(--sg-orange); }

/* ---------- order ---------- */
.shop-transfer { margin-bottom: 24px; border-color: var(--sg-orange); background: var(--sg-selected-bg, #fffbeb); }
.shop-transfer dl { display: grid; grid-template-columns: max-content 1fr; gap: 8px 20px; margin: 0 0 12px; }
.shop-transfer dt { color: var(--sg-muted); }
.shop-transfer dd { margin: 0; font-weight: 700; }
.shop-payment { margin-bottom: 24px; border-color: var(--sg-orange); }
.shop-payment form { margin: 12px 0 0; }
.shop-invoice { margin-bottom: 24px; }
.shop-table { width: 100%; border-collapse: collapse; }
.shop-table th, .shop-table td { padding: 10px 8px; border-bottom: 1px solid var(--sg-line); text-align: left; vertical-align: top; }
.shop-table small { color: var(--sg-muted); }
.shop-table tfoot td { border-bottom: 0; padding-block: 6px; }
.shop-table .shop-num { text-align: right; white-space: nowrap; }
.shop-total td { font-size: 18px; font-weight: 800; border-top: 2px solid var(--sg-text, #111827); }

@media (max-width: 900px) {
  .shop-layout { grid-template-columns: 1fr; }
  .shop-summary { position: static; }
}

@media (max-width: 640px) {
  .shop-card { padding: 18px; }
  .shop-line { grid-template-columns: 1fr auto; }
  .shop-line-info { grid-column: 1 / -1; }
  .shop-line-remove { justify-self: end; }
  .shop-line-total { grid-column: 1 / -1; text-align: left; }
  .shop-table thead { display: none; }
  .shop-table tbody td { display: block; padding: 2px 0; border: 0; }
  .shop-table tbody tr { display: block; padding: 10px 0; border-bottom: 1px solid var(--sg-line); }
  .shop-table tbody .shop-num { text-align: left; }
}

/* fitting appointments */
.shop-fitting-slot { margin-top: 16px; }
.shop-strike { text-decoration: line-through; color: var(--sg-muted); }
.shop-appointment { margin-bottom: 24px; }
.shop-appointment-slot { font-size: 22px; font-weight: 800; margin: 0 0 12px; }
.shop-appointment dl { display: grid; grid-template-columns: max-content 1fr; gap: 8px 20px; margin: 0 0 16px; }
.shop-appointment dt { color: var(--sg-muted); }
.shop-appointment dd { margin: 0; }

/* comparison */
.compare-form { margin: 0; }
.compare-button-added { border-color: var(--sg-text, #111827); }
.comparison-hint { color: var(--sg-muted); font-size: 15px; }
.comparison-scroll { overflow-x: auto; margin: 0 -8px; padding: 0 8px; }
.comparison-table { width: 100%; min-width: 560px; border-collapse: collapse; table-layout: fixed; }
.comparison-table th, .comparison-table td { padding: 10px 12px; border-bottom: 1px solid var(--sg-line); text-align: left; vertical-align: top; }
.comparison-table tbody th { width: 170px; color: var(--sg-muted); font-size: 14px; font-weight: 600; }
.comparison-table thead th { vertical-align: bottom; }
.comparison-table thead th:first-child { width: 170px; }
.comparison-picture { display: block; width: 96px; height: 96px; margin: 0 0 10px; text-decoration: none; }
.comparison-picture img { display: block; width: 100%; height: 100%; object-fit: contain; }
.comparison-name { display: block; margin: 0 0 6px; color: var(--sg-text, #111827); font-weight: 800; }
.comparison-price { font-size: 18px; font-weight: 800; }
.comparison-price small { color: var(--sg-muted); font-size: 13px; font-weight: 400; }
.comparison-differs td, .comparison-differs th { background: var(--sg-diff-bg, #fff7e6); }
.comparison-legend { margin: 12px 0; color: var(--sg-muted); font-size: 14px; }
.comparison-legend::before { content: ""; display: inline-block; width: 12px; height: 12px; margin-right: 6px; border-radius: 3px; background: var(--sg-diff-bg, #fff7e6); border: 1px solid var(--sg-diff-line, #f5d9a6); vertical-align: -1px; }

@media (max-width: 640px) {
  .comparison-table tbody th, .comparison-table thead th:first-child { width: 110px; }
  .comparison-picture { width: 72px; height: 72px; }
}

/* customer account */
.account-narrow { max-width: 520px; }
.account-links { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 16px; font-size: 15px; }
.account-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 24px; align-items: start; }
.account-nav { display: flex; flex-direction: column; gap: 4px; padding: 12px; border: 1px solid var(--sg-line); border-radius: 16px; background: var(--sg-card, #fff); }
.account-nav a { padding: 8px 12px; border-radius: 10px; color: var(--sg-text, #111827); font-weight: 600; text-decoration: none; }
.account-nav a:hover { background: var(--sg-hover, #f1f5f9); }
.account-nav a.active { background: var(--sg-brand, #111827); color: var(--sg-on-brand, #fff); }
.account-sign-out { margin: 8px 0 0; }
.account-sign-out button { width: 100%; }
.account-data { margin-top: 24px; }

@media (max-width: 900px) {
  .account-layout { grid-template-columns: 1fr; }
  .account-nav { flex-direction: row; flex-wrap: wrap; }
  .account-sign-out { margin: 0; }
  .account-sign-out button { width: auto; }
}

.shop-appointment-move { margin: 16px 0; }

/* ---------- pages and news ---------- */
.content-page { max-width: 820px; line-height: 1.65; }
.content-page h2 { margin-top: 1.6em; font-size: 20px; }
.content-page h3 { margin-top: 1.3em; font-size: 17px; }
.content-page ul { padding-left: 22px; }
.content-updated,
.news-date { color: var(--sg-muted); font-size: 13px; }
.news-list { display: grid; gap: 16px; padding: 0; list-style: none; }
.news-list h2 { margin: 4px 0 6px; font-size: 19px; }
.news-list h2 a { color: inherit; text-decoration: none; }
.news-list h2 a:hover { text-decoration: underline; }
.news-list p { margin: 0; }

/* ---------- drop-downs of the storefront ----------
   Every browser: own chevron instead of the system arrow. Chromium (appearance: base-select): the opened list is styled too;
   the other browsers keep their native list. */
:is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) select {
  appearance: none;
  padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%236b7280' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 15px center;
  background-size: 12px 8px;
  cursor: pointer;
}
:is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) select:focus-visible { outline: 2px solid var(--sg-orange); outline-offset: 1px; }

@supports (appearance: base-select) {
  :is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) select,
  :is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) select::picker(select) { appearance: base-select; }
  :is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) select { display: flex; align-items: center; }
  :is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) select::picker-icon { display: none; }
  :is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) select::picker(select) {
    max-height: min(340px, 60vh);
    margin-block: 6px;
    padding: 6px;
    overflow-y: auto;
    border: 1px solid var(--sg-line, #e5e7eb);
    border-radius: 14px;
    background: var(--sg-card, #fff);
    color: var(--sg-text, #111827);
    box-shadow: 0 18px 40px rgba(15, 23, 42, .18);
    scrollbar-width: thin;
  }
  :is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) option {
    padding: 9px 12px;
    border-radius: 9px;
    font-size: 15px;
    cursor: pointer;
  }
  :is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) option:hover,
  :is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) option:focus-visible { outline: none; background: var(--sg-hover, #f1f5f9); }
  :is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) option:checked { background: var(--sg-selected-bg, #fffbeb); font-weight: 700; }
  :is(.tire-field, .tire-search-bar-options, .tire-results-head, .shop-field) option::checkmark { color: var(--sg-orange-dark, #d97706); }
}

/* product reviews */
.product-rating { margin: 8px 0; }
.product-rating a { color: inherit; }
.product-rating span[aria-hidden], .product-stars, .product-review-rating span[aria-hidden] { color: var(--sg-orange, #f28c00); letter-spacing: 1px; }
.product-review-list { list-style: none; margin: 0 0 20px; padding: 0; }
.product-review-list li { padding: 12px 0; border-bottom: 1px solid var(--sg-line); }
.product-review-list p { margin: 0 0 4px; }
.product-review-text { white-space: pre-line; }
.product-review-form { max-width: 640px; }
.product-review-rating { border: 0; padding: 0; margin: 0 0 12px; }
.product-review-rating .shop-option { display: inline-flex; margin-right: 12px; }
