/* Piros: a light storefront, cool photographic panels and scarlet shopping actions. */
:root {
  --sg-radius: 16px;
  --sg-page: #f3f7fb;
  --sg-surface: #eaf3fb;
  --sg-card: #fff;
  --sg-line: #d7e3ef;
  --sg-text: #14213a;
  --sg-muted: #52617a;
  --sg-navy: #14213a;
  --sg-navy-soft: #253553;
  --sg-brand: #14213a;
  --sg-brand-soft: #253553;
  --sg-orange: #ce1738;
  --sg-orange-dark: #a50f2a;
  --sg-on-accent: #fff;
  --sg-hover: #edf5fd;
  --sg-selected-bg: #fff0f3;
  --sg-diff-bg: #fff0f3;
  --sg-diff-line: #f0bfca;
  --sg-heading-font: "Segoe UI", system-ui, sans-serif;
  --sg-tread: none;
  --sg-showcase-grid: "intro photo" "search search" / minmax(0, .9fr) minmax(0, 1.1fr);
  --sg-showcase-bg: linear-gradient(115deg, #f8fcff, #dcecfb);
  --sg-showcase-photo-position: 64% center;
  --sg-showcase-photo-height: clamp(280px, 30vw, 430px);
  --sg-showcase-radius: 24px;
  --sg-showcase-category-ratio: 1.7;
  --sg-showcase-action-color: var(--sg-orange-dark);
  --sg-showcase-weight: 690;
}

.tire-hero.tire-showcase { column-gap: clamp(20px, 3.8vw, 52px); }
.tire-showcase .tire-hero-text { align-self: center; }
.tire-showcase .tire-hero-text h1 { max-width: 13ch; }
.tire-showcase .tire-hero-text p { max-width: 36ch; }
.tire-showcase .tire-showcase-photo {
  background-image: url("piros-hero.jpg");
  box-shadow: 0 14px 36px rgb(34 65 105 / .16);
}
.tire-showcase .tire-quick-search {
  position: relative;
  z-index: 1;
  box-shadow: 0 14px 40px rgb(34 65 105 / .13);
}
.tire-showcase .tire-quick-search .tire-button-primary,
.tire-card .tire-button-primary,
.tire-row .tire-button-primary { border-radius: 10px; }

.tire-home-grid .tire-home-card:is(.tire-home-season, .tire-home-vehicle) {
  box-shadow: 0 6px 20px rgb(34 65 105 / .07);
}
.tire-home-grid .tire-home-card-link { color: var(--sg-orange-dark); }
.tire-row,
.tire-search-bar,
.tire-filters { border-radius: var(--sg-radius); }

@media (min-width: 821px) {
  .tire-showcase .tire-quick-search { margin: -42px clamp(4px, 3vw, 40px) 0; }
  .tire-showcase .tire-selectors { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .tire-showcase .tire-field-brand { grid-column: auto; }
}

.site-header-upper { background: var(--sg-orange); }
.site-header-upper .site-header-links a { color: #fff; }
.site-header-upper .site-header-links a:hover { text-decoration: underline; }
.site-header-lower { padding-block: 14px; }
.site-menu { border-color: var(--sg-line); background: #fff; }
.site-menu a { padding-block: 14px; color: var(--sg-text); }
.site-menu a:hover,
.site-menu a.active { color: var(--sg-orange-dark); }

/* The catalogue uses the same visual hierarchy in featured and search cards. */
.tire-search-page .tire-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 236px), 1fr));
  align-items: stretch;
  gap: 18px;
}

.tire-search-page .tire-list .tire-row,
.tire-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--sg-line);
  border-radius: var(--sg-radius);
  background: var(--sg-card);
  box-shadow: 0 3px 14px rgb(34 65 105 / .06);
}

.tire-search-page .tire-row-picture,
.tire-card-picture {
  display: grid;
  place-items: center;
  width: 100%;
  height: auto;
  aspect-ratio: 1.65;
  margin: 0;
  overflow: hidden;
  border-radius: 10px;
  background: linear-gradient(150deg, #f8fbff, #eaf3fb);
}

.tire-search-page .tire-row-picture img,
.tire-card-picture img {
  width: 100%;
  height: 100%;
  min-height: 0;
  padding: 8px;
  object-fit: contain;
}

.tire-search-page .tire-row-picture .tire-row-placeholder,
.tire-card-picture .tire-row-placeholder {
  width: auto;
  height: 76%;
  aspect-ratio: 1;
  font-size: 10px;
}

.tire-search-page .tire-row-info { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.tire-search-page .tire-row-info h3,
.tire-card h3 {
  margin: 0;
  font-size: 16px;
  line-height: 1.35;
  font-weight: 720;
  overflow-wrap: anywhere;
}

.tire-search-page .tire-row-size {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  margin: 8px 0 0;
}

.tire-search-page .tire-row-size .tire-size-chip,
.tire-card > .tire-size-chip {
  align-self: flex-start;
  color: var(--sg-text);
  border-color: var(--sg-line);
  background: var(--sg-surface);
  font-size: 13px;
  font-weight: 750;
}

.tire-search-page .tire-row-season { font-size: 12px; }
.tire-search-page .tire-tags,
.tire-card .tire-tags { gap: 4px; }

.tire-search-page .tire-row-buy,
.tire-card-price {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding-top: 10px;
  border-top: 1px solid var(--sg-line);
}

.tire-card-price { display: block; margin-top: auto; }
.tire-card-price .tire-set-price { margin-top: 3px; }

.tire-search-page .tire-row-price,
.tire-card-price {
  color: var(--sg-text);
  font-size: 23px;
  font-weight: 780;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.tire-search-page .tire-row-price small,
.tire-card-price small,
.tire-search-page .tire-set-price,
.tire-card-price .tire-set-price { color: var(--sg-muted); font-size: 12px; }

:is(.tire-search-page .tire-row, .tire-card) .tire-stock {
  align-self: flex-start;
  padding: 3px 9px;
  font-size: 11px;
  font-weight: 700;
}
:is(.tire-search-page .tire-row, .tire-card) .tire-stock-plenty {
  background: #e6f5ed;
  color: #15583b;
}
:is(.tire-search-page .tire-row, .tire-card) .tire-stock-onorder {
  background: #fff3dc;
  color: #744700;
}

.tire-search-page .tire-row-actions,
.tire-card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  width: 100%;
}

:is(.tire-search-page .tire-row-actions, .tire-card-actions) .tire-button {
  min-height: 44px;
  width: auto;
  padding-inline: 10px;
  border-radius: 8px;
  font-size: 13px;
}

:is(.tire-search-page .tire-row-actions, .tire-card-actions) .tire-button-ghost {
  border-color: transparent;
  background: transparent;
  color: var(--sg-muted);
}
:is(.tire-search-page .tire-row-actions, .tire-card-actions) .tire-button-ghost:hover,
:is(.tire-search-page .tire-row-actions, .tire-card-actions) .tire-button-ghost:focus-visible {
  border-color: var(--sg-line);
  color: var(--sg-text);
}

/* Keep the quantity and purchase controls together. */
:is(.tire-search-page .tire-row-actions, .tire-card-actions) .shop-add {
  flex: 1 1 100%;
  flex-wrap: nowrap;
  min-width: 0;
}
:is(.tire-search-page .tire-row-actions, .tire-card-actions) .shop-add .tire-button-primary { flex: 1; }
:is(.tire-search-page .tire-row-actions, .tire-card-actions) .shop-quantity input { width: 48px; }
