/* ══════════════════════════════════════════════
   Shop extras: cautare live, wishlist, comparare
   ══════════════════════════════════════════════ */

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

/* ─────────────── Bara de cautare magazin ─────────────── */

.sp-search {
  position: relative;
  margin-bottom: 18px;
  z-index: 60;
}

.sp-search-form {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 6px 6px 16px;
  background: #fff;
  border: 1px solid rgba(14, 73, 121, 0.14);
  border-radius: 999px;
  box-shadow: 0 10px 30px -18px rgba(8, 42, 77, 0.35);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.sp-search-form:focus-within {
  border-color: var(--color-green, #29b46b);
  box-shadow: 0 14px 34px -16px rgba(41, 180, 107, 0.45);
}

.sp-search-icon {
  display: grid;
  place-items: center;
  color: #6b7f8e;
  flex: none;
}

.sp-search-icon svg {
  width: 19px;
  height: 19px;
}

.sp-search-input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  font: inherit;
  font-size: 0.98rem;
  color: inherit;
  padding: 9px 0;
}

.sp-search-input::-webkit-search-cancel-button {
  cursor: pointer;
}

.sp-search-submit {
  flex: none;
  border: 0;
  cursor: pointer;
  padding: 10px 22px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.92rem;
  color: #06281a;
  background: linear-gradient(135deg, var(--color-green, #29b46b) 0%, #93d94e 100%);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.sp-search-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px -10px rgba(41, 180, 107, 0.55);
}

.sp-search-suggestions {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: #fff;
  border: 1px solid rgba(14, 73, 121, 0.12);
  border-radius: 18px;
  box-shadow: 0 26px 60px -22px rgba(8, 42, 77, 0.45);
  overflow: hidden;
  z-index: 80;
}

.sp-search-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  text-decoration: none;
  color: inherit;
  transition: background 0.15s ease;
}

.sp-search-item:hover,
.sp-search-item:focus-visible {
  background: rgba(41, 180, 107, 0.08);
  outline: none;
}

.sp-search-item + .sp-search-item {
  border-top: 1px solid rgba(14, 73, 121, 0.07);
}

.sp-search-item-media {
  flex: none;
  width: 46px;
  height: 46px;
  border-radius: 10px;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: #f1f5f8;
  border: 1px solid rgba(14, 73, 121, 0.08);
}

.sp-search-item-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sp-search-item-media em {
  font-style: normal;
  font-weight: 800;
  font-size: 1.05rem;
  color: #8296a5;
}

.sp-search-item-copy {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.sp-search-item-copy strong {
  font-size: 0.93rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sp-search-item-copy small {
  font-size: 0.78rem;
  color: #7c8d9b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sp-search-item-price {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.sp-search-item-price strong {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--color-navy, #0d416d);
}

.sp-search-item-price small {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.sp-search-item-price small.is-stock {
  color: #1d9d5f;
}

.sp-search-item-price small.is-order {
  color: #b07d1e;
}

.sp-search-more {
  display: block;
  padding: 11px 14px;
  text-align: center;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--color-green, #1d9d5f);
  text-decoration: none;
  background: rgba(41, 180, 107, 0.06);
  border-top: 1px solid rgba(14, 73, 121, 0.08);
}

.sp-search-more:hover,
.sp-search-more:focus-visible {
  background: rgba(41, 180, 107, 0.13);
  outline: none;
}

.sp-search-empty {
  padding: 16px 14px;
  text-align: center;
  font-size: 0.9rem;
  color: #7c8d9b;
}

html.theme-dark .sp-search-form,
html.theme-dark .sp-search-suggestions {
  background: rgba(18, 27, 42, 0.98);
  border-color: rgba(255, 255, 255, 0.1);
}

html.theme-dark .sp-search-item:hover,
html.theme-dark .sp-search-item:focus-visible {
  background: rgba(41, 180, 107, 0.14);
}

html.theme-dark .sp-search-item + .sp-search-item {
  border-top-color: rgba(255, 255, 255, 0.07);
}

html.theme-dark .sp-search-item-media {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.08);
}

html.theme-dark .sp-search-item-price strong {
  color: #cfe6f7;
}

html.theme-dark .sp-search-more {
  background: rgba(41, 180, 107, 0.1);
  border-top-color: rgba(255, 255, 255, 0.08);
}

/* ─────────────── Butoane rapide pe cardul din magazin ─────────────── */

.sp-card {
  position: relative;
}

.sp-card-quick {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 5;
}

.sp-quick-btn {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(14, 73, 121, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: #486072;
  cursor: pointer;
  box-shadow: 0 8px 20px -10px rgba(8, 42, 77, 0.4);
  transition: transform 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.sp-quick-btn svg {
  width: 17px;
  height: 17px;
  fill: none;
}

.sp-quick-btn:hover {
  transform: scale(1.08);
}

.sp-quick-wishlist:hover {
  color: #e0245e;
}

.sp-quick-wishlist.is-active {
  color: #fff;
  background: linear-gradient(135deg, #f0567e 0%, #e0245e 100%);
  border-color: transparent;
}

.sp-quick-wishlist.is-active svg {
  fill: currentColor;
}

.sp-quick-compare:hover {
  color: var(--color-green, #1d9d5f);
}

.sp-quick-compare.is-active {
  color: #06281a;
  background: linear-gradient(135deg, var(--color-green, #29b46b) 0%, #93d94e 100%);
  border-color: transparent;
}

html.theme-dark .sp-quick-btn {
  background: rgba(18, 27, 42, 0.92);
  border-color: rgba(255, 255, 255, 0.12);
  color: #b9cbd8;
}

/* ─────────────── Butoane pe pagina produsului ─────────────── */

.pp-stage {
  position: relative;
}

.pp-stage-wishlist {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 6;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px 8px 11px;
  border: 1px solid rgba(14, 73, 121, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: #486072;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 20px -10px rgba(8, 42, 77, 0.4);
  transition: transform 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.pp-stage-wishlist svg {
  width: 17px;
  height: 17px;
  fill: none;
}

.pp-stage-wishlist:hover {
  transform: translateY(-1px);
  color: #e0245e;
}

.pp-stage-wishlist.is-active {
  color: #fff;
  background: linear-gradient(135deg, #f0567e 0%, #e0245e 100%);
  border-color: transparent;
}

.pp-stage-wishlist.is-active svg {
  fill: currentColor;
}

html.theme-dark .pp-stage-wishlist {
  background: rgba(18, 27, 42, 0.92);
  border-color: rgba(255, 255, 255, 0.12);
  color: #b9cbd8;
}

.pp-actions-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.pp-actions-grid .pp-actions-full {
  grid-column: 1 / -1;
}

.pp-actions-grid .pp-btn {
  width: 100%;
  justify-content: center;
}

@media (max-width: 520px) {
  .pp-actions-grid {
    grid-template-columns: 1fr;
  }
}

.pp-btn-compare.is-active {
  color: var(--color-green, #1d9d5f);
  border-color: rgba(41, 180, 107, 0.4);
  background: rgba(41, 180, 107, 0.08);
}

/* ─────────────── Bara plutitoare de comparare ─────────────── */

.egs-compare-bar {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translate(-50%, 20px);
  max-width: min(680px, calc(100vw - 24px));
  width: max-content;
  z-index: 1600;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
}

.egs-compare-bar.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.egs-compare-bar-inner {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  background: rgba(10, 30, 48, 0.97);
  color: #eaf3fa;
  border-radius: 999px;
  box-shadow: 0 22px 55px -18px rgba(4, 20, 34, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.egs-compare-bar-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.86rem;
  font-weight: 700;
  white-space: nowrap;
}

.egs-compare-bar-label svg {
  width: 17px;
  height: 17px;
}

.egs-compare-bar-label em {
  font-style: normal;
  display: grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  font-size: 0.78rem;
  background: var(--color-green, #29b46b);
  color: #06281a;
}

.egs-compare-bar-items {
  display: flex;
  align-items: center;
  gap: 8px;
}

.egs-compare-bar-item {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  overflow: visible;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
  display: grid;
  place-items: center;
}

.egs-compare-bar-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 9px;
}

.egs-compare-bar-item em {
  font-style: normal;
  font-weight: 800;
  color: #b9cbd8;
}

.egs-compare-bar-item button {
  position: absolute;
  top: -7px;
  right: -7px;
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: #e0245e;
  color: #fff;
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
}

.egs-compare-bar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.egs-compare-bar-go {
  padding: 9px 18px;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 800;
  text-decoration: none;
  color: #06281a;
  background: linear-gradient(135deg, var(--color-green, #29b46b) 0%, #93d94e 100%);
  white-space: nowrap;
}

.egs-compare-bar-clear {
  border: 0;
  background: transparent;
  color: #9fb4c4;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  padding: 6px 8px;
}

.egs-compare-bar-clear:hover {
  color: #fff;
}

@media (max-width: 760px) {
  .egs-compare-bar {
    bottom: calc(84px + env(safe-area-inset-bottom, 0px));
  }

  .egs-compare-bar-inner {
    gap: 10px;
    padding: 8px 12px;
  }

  .egs-compare-bar-label span {
    display: none;
  }
}

/* ─────────────── Pagini favorite & comparare ─────────────── */

.sx-page {
  min-height: 60vh;
}

.sx-hero .container,
.sx-body .container {
  max-width: 1280px;
  margin: 0 auto;
  padding-left: clamp(16px, 3vw, 28px);
  padding-right: clamp(16px, 3vw, 28px);
}

.sx-hero {
  padding: clamp(28px, 5vw, 52px) 0 clamp(18px, 3vw, 30px);
  background: linear-gradient(160deg, rgba(41, 180, 107, 0.08) 0%, rgba(13, 65, 109, 0.06) 100%);
}

.sx-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  margin-bottom: 12px;
  color: #7c8d9b;
}

.sx-breadcrumbs a {
  color: inherit;
  text-decoration: none;
}

.sx-breadcrumbs a:hover {
  color: var(--color-green, #1d9d5f);
}

.sx-hero h1 {
  margin: 0 0 6px;
  font-size: clamp(1.5rem, 3vw, 2.1rem);
}

.sx-hero p {
  margin: 0;
  color: #62788a;
}

.sx-body {
  padding: clamp(20px, 4vw, 40px) 0 clamp(40px, 6vw, 70px);
}

.sx-empty {
  max-width: 440px;
  margin: 30px auto;
  text-align: center;
  padding: 40px 26px;
  background: #fff;
  border: 1px solid rgba(14, 73, 121, 0.1);
  border-radius: 22px;
  box-shadow: 0 20px 50px -30px rgba(8, 42, 77, 0.4);
}

.sx-empty-icon {
  display: inline-grid;
  place-items: center;
  width: 68px;
  height: 68px;
  margin-bottom: 14px;
  border-radius: 999px;
  color: var(--color-green, #1d9d5f);
  background: rgba(41, 180, 107, 0.1);
}

.sx-empty h2 {
  margin: 0 0 8px;
  font-size: 1.2rem;
}

.sx-empty p {
  margin: 0 0 18px;
  color: #62788a;
  font-size: 0.93rem;
}

.sx-btn-primary {
  display: inline-block;
  padding: 11px 26px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.92rem;
  text-decoration: none;
  color: #06281a;
  background: linear-gradient(135deg, var(--color-green, #29b46b) 0%, #93d94e 100%);
}

.sx-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 18px;
}

.sx-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid rgba(14, 73, 121, 0.1);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 16px 40px -28px rgba(8, 42, 77, 0.45);
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.sx-card:hover {
  transform: translateY(-3px);
}

.sx-card.is-removing {
  opacity: 0;
  transform: scale(0.96);
}

.sx-card-media {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  background: #f1f5f8;
  text-decoration: none;
}

.sx-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sx-card-letter {
  font-size: 2.4rem;
  font-weight: 800;
  color: #a5b7c3;
}

.sx-card-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  font-style: normal;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 4px 10px;
  border-radius: 999px;
}

.sx-card-tag.is-stock {
  color: #0d5c37;
  background: rgba(41, 180, 107, 0.16);
}

.sx-card-tag.is-order {
  color: #7c5a12;
  background: rgba(240, 180, 41, 0.2);
}

.sx-card-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px 16px 16px;
  flex: 1;
}

.sx-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.78rem;
  color: #7c8d9b;
}

.sx-card-body h3 {
  margin: 0;
  font-size: 0.99rem;
  line-height: 1.35;
}

.sx-card-body h3 a {
  color: inherit;
  text-decoration: none;
}

.sx-card-body h3 a:hover {
  color: var(--color-green, #1d9d5f);
}

.sx-card-price {
  margin-top: auto;
  display: flex;
  flex-direction: column;
}

.sx-card-price strong {
  font-size: 1.08rem;
  color: var(--color-navy, #0d416d);
}

.sx-card-price small {
  color: #7c8d9b;
  font-size: 0.79rem;
}

.sx-card-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sx-card-actions form {
  flex: 1;
}

.sx-btn-cart {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  padding: 10px 14px;
  border: 0;
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.86rem;
  cursor: pointer;
  color: #06281a;
  background: linear-gradient(135deg, var(--color-green, #29b46b) 0%, #93d94e 100%);
}

.sx-btn-detail {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.86rem;
  text-decoration: none;
  color: var(--color-navy, #0d416d);
  border: 1px solid rgba(14, 73, 121, 0.18);
}

.sx-btn-remove {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 13px;
  border-radius: 999px;
  border: 1px solid rgba(224, 36, 94, 0.25);
  background: transparent;
  color: #c21e50;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
}

.sx-btn-remove:hover {
  background: rgba(224, 36, 94, 0.08);
}

/* Tabel comparare */

.sx-compare-hint {
  margin-bottom: 16px;
  padding: 12px 18px;
  border-radius: 14px;
  background: rgba(240, 180, 41, 0.12);
  border: 1px solid rgba(240, 180, 41, 0.3);
  font-size: 0.9rem;
}

.sx-compare-hint p {
  margin: 0;
}

.sx-compare-scroll {
  overflow-x: auto;
  border: 1px solid rgba(14, 73, 121, 0.1);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 20px 50px -30px rgba(8, 42, 77, 0.4);
}

.sx-compare-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
}

.sx-compare-table th,
.sx-compare-table td {
  padding: 13px 16px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid rgba(14, 73, 121, 0.08);
  font-size: 0.9rem;
}

.sx-compare-table tbody th {
  width: 170px;
  min-width: 140px;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #7c8d9b;
  font-weight: 700;
  background: rgba(14, 73, 121, 0.03);
}

.sx-compare-table thead th {
  border-bottom: 2px solid rgba(14, 73, 121, 0.12);
}

.sx-compare-product {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  min-width: 150px;
}

.sx-compare-remove {
  position: absolute;
  top: 0;
  right: 0;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: rgba(224, 36, 94, 0.1);
  color: #c21e50;
  font-size: 15px;
  cursor: pointer;
  padding: 0;
}

.sx-compare-remove:hover {
  background: #e0245e;
  color: #fff;
}

.sx-compare-media {
  display: grid;
  place-items: center;
  width: 84px;
  height: 84px;
  border-radius: 14px;
  overflow: hidden;
  background: #f1f5f8;
  border: 1px solid rgba(14, 73, 121, 0.08);
  text-decoration: none;
}

.sx-compare-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sx-compare-media span {
  font-size: 1.7rem;
  font-weight: 800;
  color: #a5b7c3;
}

.sx-compare-name {
  font-weight: 700;
  font-size: 0.92rem;
  color: inherit;
  text-decoration: none;
  line-height: 1.3;
}

.sx-compare-name:hover {
  color: var(--color-green, #1d9d5f);
}

.sx-compare-price {
  display: block;
  font-size: 1.02rem;
  color: var(--color-navy, #0d416d);
}

.sx-compare-table td small {
  color: #7c8d9b;
  font-size: 0.78rem;
}

.sx-compare-stock {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 4px 10px;
  border-radius: 999px;
}

.sx-compare-stock.is-stock {
  color: #0d5c37;
  background: rgba(41, 180, 107, 0.16);
}

.sx-compare-stock.is-order {
  color: #7c5a12;
  background: rgba(240, 180, 41, 0.2);
}

.sx-compare-desc {
  max-width: 260px;
  color: #62788a;
}

/* Dark theme pentru paginile sx */

html.theme-dark .sx-hero {
  background: linear-gradient(160deg, rgba(41, 180, 107, 0.1) 0%, rgba(10, 30, 48, 0.4) 100%);
}

html.theme-dark .sx-empty,
html.theme-dark .sx-card,
html.theme-dark .sx-compare-scroll {
  background: rgba(18, 27, 42, 0.94);
  border-color: rgba(255, 255, 255, 0.09);
}

html.theme-dark .sx-card-media,
html.theme-dark .sx-compare-media {
  background: rgba(255, 255, 255, 0.05);
}

html.theme-dark .sx-card-price strong,
html.theme-dark .sx-compare-price {
  color: #cfe6f7;
}

html.theme-dark .sx-btn-detail {
  color: #cfe6f7;
  border-color: rgba(255, 255, 255, 0.16);
}

html.theme-dark .sx-compare-table tbody th {
  background: rgba(255, 255, 255, 0.03);
}

html.theme-dark .sx-compare-table th,
html.theme-dark .sx-compare-table td {
  border-bottom-color: rgba(255, 255, 255, 0.07);
}
