/* ============================================================
   eZapalovače.cz – PDP Enhancement Styles
   ============================================================ */

:root {
  --ez-text: #234069;
  --ez-text-secondary: #5a6478;
  --ez-text-muted: #8a92a3;
  --ez-border: #cbd5e0;
  --ez-border-light: #e2e8f0;
  --ez-bg-card: #ffffff;
  --ez-radius: 8px;
}

/* ============================================================
   QUICK PARAMS
   ============================================================ */
.ez-quick-params {
  display: grid;
  gap: 0;
  background: var(--ez-bg-card);
  border: 1px solid var(--ez-border);
  border-radius: var(--ez-radius);
  overflow: hidden;
  margin: 16px 0 0 -5.6053811659%;
  width: calc(100% + 5.6053811659%);
  box-sizing: border-box;
}

.ez-quick-params[data-cols="2"] { grid-template-columns: 1fr 1fr; }
.ez-quick-params[data-cols="3"] { grid-template-columns: 1fr 1fr 1fr; }
.ez-quick-params[data-cols="4"] { grid-template-columns: 1fr 1fr 1fr 1fr; }

.ez-quick-param {
  background: var(--ez-bg-card);
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.ez-quick-param + .ez-quick-param {
  border-left: 1px solid var(--ez-border-light);
}

.ez-quick-param__label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--ez-text-muted);
  font-weight: 500;
}

.ez-quick-param__value {
  font-size: 14px;
  font-weight: 600;
  color: var(--ez-text);
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ez-quick-param__value a {
  color: var(--ez-text);
  text-decoration: underline;
  text-decoration-color: var(--ez-border);
  text-underline-offset: 3px;
}

.ez-quick-param__value a:hover {
  text-decoration-color: var(--ez-text);
}

/* ============================================================
   KÓD PRODUKTU – přesunut JS-em na vlastní řádek (desktop)
   Na mobilu necháváme Shopion default (skrytí přes JS)
   ============================================================ */
.ez-product-code-row {
  margin: 8px 0 0 -5.6053811659%;
  width: calc(100% + 5.6053811659%);
  text-align: right;
  font-size: 13px;
  color: var(--ez-text-muted);
  box-sizing: border-box;
}

.ez-product-code-row .detail_number {
  font-weight: 600;
  color: var(--ez-text-secondary);
}

/* Schovat všechny původní výskyty kódu produktu — JS jeden přesune na vrch */
.product-detail__main .product-detail__main-product-code,
.product-detail__main-variants .product-detail__main-product-code,
.product-detail__main-box .product-detail__main-product-code {
  display: none !important;
}

/* Naopak ez-product-code-row ZOBRAZIT */
.ez-product-code-row {
  display: block !important;
}

/* ============================================================
   SHOPION DELIVERY BOX
   ============================================================ */

.product-detail__main-delivery {
  background: var(--ez-bg-card);
  border: 1px solid var(--ez-border);
  border-radius: var(--ez-radius);
  padding: 14px 16px !important;
  margin-top: 16px !important;
  margin-left: -5.6053811659% !important;
  width: calc(100% + 5.6053811659%);
  box-sizing: border-box;
  flex-direction: column;
}

.product-detail__main-delivery-options {
  flex: 1 1 100% !important;
  padding-right: 0 !important;
  list-style: none;
  margin: 0;
  padding: 0;
  width: 100%;
}

.product-detail__main-delivery-options-item {
  position: relative;
  display: block;
  padding: 0 0 0 28px !important;
  font-weight: 400;
  line-height: 1.5;
  font-size: 13.5px;
  color: var(--ez-text);
  margin: 0;
  letter-spacing: 0;
}

.product-detail__main-delivery-options-item + .product-detail__main-delivery-options-item {
  margin-top: 9px;
  padding-top: 9px !important;
  border-top: 1px solid var(--ez-border-light);
}

/* === Ikony === */
.product-detail__main-delivery-options-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 4px;
  width: 18px;
  height: 18px;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
}

.product-detail__main-delivery-options-item + .product-detail__main-delivery-options-item::before {
  top: 13px;
}

.ez-row-address::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238a92a3' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 18H3c-.6 0-1-.4-1-1V7c0-.6.4-1 1-1h10c.6 0 1 .4 1 1v11'/%3E%3Cpath d='M14 9h4l4 4v4c0 .6-.4 1-1 1h-2'/%3E%3Ccircle cx='7' cy='18' r='2'/%3E%3Ccircle cx='17' cy='18' r='2'/%3E%3C/svg%3E");
}

.ez-row-pickup::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238a92a3' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0118 0z'/%3E%3Ccircle cx='12' cy='10' r='3'/%3E%3C/svg%3E");
}

.ez-row-store::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238a92a3' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9h18M3 15h18M5 4h14a2 2 0 012 2v12a2 2 0 01-2 2H5a2 2 0 01-2-2V6a2 2 0 012-2z'/%3E%3C/svg%3E");
}

.ez-row-return::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238a92a3' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9l9-7 9 7v11a2 2 0 01-2 2H5a2 2 0 01-2-2z'/%3E%3Cpolyline points='9 22 9 12 15 12 15 22'/%3E%3C/svg%3E");
}

/* Odkazy decentní */
.product-detail__main-delivery-options-item a.link {
  color: var(--ez-text-secondary);
  text-decoration: underline;
  text-decoration-color: var(--ez-border);
  text-underline-offset: 2px;
  font-weight: 400;
}

.product-detail__main-delivery-options-item a.link:hover {
  color: var(--ez-text);
  text-decoration-color: var(--ez-text);
}

.product-detail__main-delivery-options-item strong {
  color: var(--ez-text);
  font-weight: 600;
}

.ez-row-return .ez-return-emphasis {
  color: var(--ez-text);
  font-weight: 600;
}

.ez-row-return .ez-return-hint {
  color: var(--ez-text-muted);
  margin-left: 6px;
  font-size: 12.5px;
}

.product-detail__main-delivery-price:empty {
  display: none;
}

.product-detail__main-delivery-info {
  display: none !important;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 767px) {
  .ez-quick-params,
  .ez-product-code-row,
  .product-detail__main-delivery {
    margin-left: 0 !important;
    width: 100% !important;
  }

  .product-detail__main-delivery {
    padding: 12px 16px !important;
  }

  .product-detail__main-delivery-options {
    display: block !important;
  }

  .product-detail__main-delivery-options-item {
    font-size: 13px;
  }

  .ez-quick-param__value {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    word-break: break-word;
  }

  /* Mobile: žádný posun, levé zarovnání */
  .ez-product-code-row {
    text-align: left;
    margin-top: 4px;
  }
}

@media (max-width: 640px) {
  .ez-quick-param {
    padding: 8px 10px;
  }
  .ez-quick-param__label {
    font-size: 10px;
  }
  .ez-quick-param__value {
    font-size: 13px;
  }
}
