/* CloudWolf Configurator & Quote Engine */

.cwqe-configurator {
  --cwqe-scroll-offset: 96px;
  --cwqe-red: #ed1c24;
  --cwqe-red-dark: #b81219;
  --cwqe-black: #050505;
  --cwqe-ink: #171717;
  --cwqe-muted: #667085;
  --cwqe-border: #e6e7eb;
  --cwqe-soft: #f7f7f8;
  position: relative;
  isolation: isolate;
  max-width: 1220px;
  margin: 0 auto;
  font-family: inherit;
  color: var(--cwqe-ink);
}

.cwqe-configurator *,
.cwqe-configurator *::before,
.cwqe-configurator *::after {
  box-sizing: border-box;
}

.cwqe-bg-lines {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 80% 10%, rgba(237,28,36,.13), transparent 28%),
    repeating-radial-gradient(ellipse at 75% 0%, rgba(237,28,36,.10) 0 1px, transparent 1px 18px);
  opacity: .8;
  z-index: -1;
}

.cwqe-hero {
  min-height: 310px;
  padding: clamp(34px, 6vw, 72px);
  border-radius: 0 0 26px 26px;
  background: linear-gradient(115deg, #000 0%, #160204 55%, #5b070c 100%);
  color: #fff;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 28px;
  align-items: center;
  overflow: hidden;
}

.cwqe-eyebrow {
  display: inline-block;
  margin-bottom: 10px;
  font-size: 12px;
  line-height: 1;
  letter-spacing: .18em;
  text-transform: uppercase;
  font-weight: 800;
  color: var(--cwqe-red);
}

.cwqe-hero h2 {
  margin: 0 0 18px;
  max-width: 700px;
  font-size: clamp(34px, 5vw, 64px);
  line-height: .98;
  letter-spacing: -.05em;
  color: #fff;
}

.cwqe-hero p {
  max-width: 760px;
  color: rgba(255,255,255,.92);
  font-size: 16px;
  line-height: 1.7;
}

.cwqe-number-pill {
  display: inline-flex;
  gap: 9px;
  align-items: center;
  margin-top: 10px;
  padding: 13px 18px;
  background: #fff;
  color: #111;
  border-radius: 999px;
  font-weight: 800;
  box-shadow: 0 16px 36px rgba(0,0,0,.18);
}

.cwqe-number-pill strong {
  color: var(--cwqe-red);
  letter-spacing: .08em;
}

.cwqe-btn {
  border: 0;
  border-radius: 999px;
  min-height: 48px;
  padding: 13px 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: 900;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}

.cwqe-btn:hover {
  transform: translateY(-1px);
}

.cwqe-btn--primary {
  background: var(--cwqe-red);
  color: #fff;
  box-shadow: 0 16px 36px rgba(237,28,36,.28);
}

.cwqe-btn--primary:hover {
  background: var(--cwqe-red-dark);
  color: #fff;
}

.cwqe-btn--ghost {
  background: #fff;
  color: var(--cwqe-red);
  border: 1px solid rgba(237,28,36,.24);
}

.cwqe-app {
  padding: 34px;
  background: #fff;
  border-radius: 0 0 28px 28px;
  box-shadow: 0 24px 70px rgba(0,0,0,.08);
}

.cwqe-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  align-items: start;
}

.cwqe-main {
  min-width: 0;
}

.cwqe-offer-banner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  padding: 15px 20px;
  border: 1px solid var(--cwqe-border);
  border-radius: 18px;
  background: rgba(255,255,255,.94);
  box-shadow: 0 14px 40px rgba(0,0,0,.05);
}

.cwqe-offer-banner span {
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  font-weight: 900;
  color: #6b7280;
}

.cwqe-offer-banner strong {
  font-size: 22px;
  color: var(--cwqe-red);
  letter-spacing: .05em;
}

.cwqe-offer-banner em {
  font-style: normal;
  font-weight: 700;
  color: #667085;
}

.cwqe-progress {
  display: grid;
  gap: 12px;
  margin: 0 0 24px;
  scroll-margin-top: var(--cwqe-scroll-offset, 96px);
}

.cwqe-progress.is-sticky {
  position: sticky;
  top: var(--cwqe-sticky-top, var(--cwqe-scroll-offset, 96px));
  z-index: 30;
  padding: 14px 0 16px;
  margin-left: -34px;
  margin-right: -34px;
  padding-left: 34px;
  padding-right: 34px;
  background: transparent;
}

.cwqe-progress-backdrop {
  position: fixed;
  z-index: 29;
  pointer-events: none;
  display: none;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(230, 231, 235, 0.95);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.06);
}

.cwqe-progress-backdrop.is-visible {
  display: block;
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .cwqe-progress-backdrop {
    background: rgba(255, 255, 255, 0.98);
  }
}

.cwqe-progress__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 16px;
}

.cwqe-progress__counter {
  font-size: 13px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #111;
}

.cwqe-progress__caption {
  font-size: 13px;
  font-weight: 700;
  color: var(--cwqe-red);
}

.cwqe-progress__track {
  height: 8px;
  border-radius: 999px;
  background: #ececec;
  overflow: hidden;
}

.cwqe-progress__fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #ed1c24, #ff5a61);
  transition: width .25s ease;
}

.cwqe-progress__items {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cwqe-progress__item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 15px;
  border-radius: 999px;
  background: #f0f0f1;
  color: #777;
  font-family: inherit;
  font-size: 12px;
  font-weight: 900;
  font-style: normal;
  text-transform: uppercase;
  letter-spacing: .1em;
  line-height: 1.2;
}

.cwqe-progress__item.is-active,
.cwqe-progress__item.is-complete {
  background: var(--cwqe-red);
  color: #fff;
}

.cwqe-progress__item--clickable {
  cursor: pointer;
  border: none;
  margin: 0;
  appearance: none;
  -webkit-appearance: none;
  transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}

.cwqe-progress__item--clickable:hover,
.cwqe-progress__item--clickable:focus-visible {
  filter: brightness(1.06);
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(237, 28, 36, 0.28);
  outline: none;
}

.cwqe-progress__item--clickable:focus-visible {
  outline: 2px solid #111;
  outline-offset: 2px;
}

.cwqe-step[aria-hidden="true"] {
  display: none !important;
}

.cwqe-panel {
  margin-bottom: 24px;
  padding: clamp(20px, 3vw, 32px);
  border: 1px solid var(--cwqe-border);
  border-radius: 26px;
  background: rgba(255,255,255,.96);
  box-shadow: 0 20px 60px rgba(0,0,0,.06);
}

.cwqe-panel h3 {
  margin: 0 0 12px;
  font-size: clamp(25px, 3vw, 34px);
  line-height: 1.12;
  color: #111;
}

.cwqe-step-header {
  scroll-margin-top: var(--cwqe-scroll-anchor-offset, calc(var(--cwqe-scroll-offset, 96px) + 132px));
}

.cwqe-step-header p,
.cwqe-panel p {
  margin: 0 0 22px;
  color: #4b5563;
  line-height: 1.7;
}

.cwqe-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(185px, 1fr));
  gap: 18px;
}

.cwqe-card {
  position: relative;
  overflow: hidden;
  min-height: 250px;
  border: 1px solid var(--cwqe-border);
  border-radius: 24px;
  background: #fff;
  cursor: pointer;
  transition: border .18s ease, box-shadow .18s ease, transform .18s ease;
}

.cwqe-card:hover {
  transform: translateY(-2px);
  border-color: rgba(237,28,36,.34);
  box-shadow: 0 18px 46px rgba(0,0,0,.09);
}

.cwqe-card.is-selected {
  border-color: var(--cwqe-red);
  box-shadow: 0 18px 52px rgba(237,28,36,.18);
}

.cwqe-card.is-required {
  box-shadow: inset 0 0 0 2px rgba(237,28,36,.35);
}

.cwqe-required-note {
  color: #b81219;
  font-weight: 800;
}

.cwqe-card:focus-visible,
.cwqe-count-card:focus-visible {
  outline: 3px solid var(--cwqe-red);
  outline-offset: 3px;
}

.cwqe-card__check {
  position: absolute;
  right: 14px;
  top: 14px;
  z-index: 2;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(0,0,0,.84);
  color: #fff;
  font-weight: 900;
}

.cwqe-card.is-selected .cwqe-card__check {
  background: var(--cwqe-red);
}

.cwqe-card__media {
  height: 158px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: linear-gradient(135deg, #fff, #f2f2f3);
}

.cwqe-card__media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 16px;
  mix-blend-mode: multiply;
}

.cwqe-card__media--placeholder span {
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  border-radius: 24px;
  background: rgba(237,28,36,.08);
  color: var(--cwqe-red);
  font-weight: 900;
  font-size: 24px;
  letter-spacing: -.04em;
}

.cwqe-card__body {
  padding: 20px;
}

.cwqe-card h4 {
  margin: 0 0 8px;
  font-size: 21px;
  line-height: 1.1;
  color: #111;
}

.cwqe-card p {
  margin: 10px 0 12px;
  color: #596273;
  font-size: 14px;
  line-height: 1.55;
}

.cwqe-sku {
  color: #7b8190;
  font-size: 12px;
  font-weight: 800;
}

.cwqe-details {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--cwqe-red);
  font-weight: 900;
  cursor: pointer;
}

.cwqe-count-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(90px, 1fr));
  gap: 14px;
  max-width: 620px;
}

.cwqe-count-card {
  min-height: 120px;
  border: 1px solid var(--cwqe-border);
  border-radius: 24px;
  background: #fff;
  color: #111;
  cursor: pointer;
  transition: .18s ease;
}

.cwqe-count-card strong {
  display: block;
  font-size: 44px;
  line-height: 1;
}

.cwqe-count-card span {
  display: block;
  margin-top: 7px;
  color: #777;
  font-weight: 800;
}

.cwqe-count-card:hover,
.cwqe-count-card.is-selected {
  color: #fff;
  background: var(--cwqe-red);
  border-color: var(--cwqe-red);
  transform: translateY(-2px);
}

.cwqe-count-card:hover span,
.cwqe-count-card.is-selected span {
  color: #fff;
}

.cwqe-circuit-block {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px dashed #d6d8df;
}

.cwqe-circuit-block h4 {
  margin: 0 0 18px;
  font-size: 20px;
}

.cwqe-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  padding: 12px 16px;
  border: 1px dashed #d6d8df;
  border-radius: 14px;
  background: #fff;
  font-weight: 700;
}

.cwqe-muted {
  color: var(--cwqe-muted);
}

.cwqe-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.cwqe-contact-form label {
  display: block;
  margin-bottom: 16px;
  font-weight: 800;
  color: #4b5563;
}

.cwqe-contact-form input,
.cwqe-contact-form textarea {
  width: 100%;
  margin-top: 8px;
  border: 1px solid #d9dce3;
  border-radius: 14px;
  padding: 13px 14px;
  font: inherit;
  color: #111;
  background: #fff;
}

.cwqe-form-status {
  margin-top: 14px;
  font-weight: 800;
  color: var(--cwqe-red);
}

.cwqe-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.cwqe-consent {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-top: 12px;
  font-size: 14px;
  line-height: 1.5;
}

.cwqe-consent input {
  margin-top: 4px;
}

.cwqe-consent a {
  color: var(--cwqe-red);
  font-weight: 700;
}

.cwqe-captcha {
  margin-top: 14px;
}

.cwqe-summary {
  position: sticky;
  top: var(--cwqe-summary-sticky-top, 128px);
  align-self: start;
  z-index: 5;
}

.cwqe-summary__inner {
  padding: 24px;
  border-radius: 28px;
  color: #fff;
  background: linear-gradient(160deg, #000 0%, #170306 54%, #4d070c 100%);
  box-shadow: 0 22px 60px rgba(0,0,0,.22);
  overflow: hidden;
}

.cwqe-summary h3 {
  margin: 0 0 16px;
  color: #fff;
  font-size: 24px;
  letter-spacing: .03em;
}

.cwqe-summary .cwqe-eyebrow {
  color: #ff535a;
}

.cwqe-summary-list {
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
}

.cwqe-summary-list li {
  padding: 13px 0;
  border-bottom: 1px solid rgba(255,255,255,.13);
}

.cwqe-summary-list span {
  display: block;
  color: rgba(255,255,255,.62);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.cwqe-summary-list strong {
  display: block;
  margin-top: 4px;
  color: #fff;
  font-size: 16px;
}

.cwqe-summary-list em {
  display: block;
  margin-top: 4px;
  color: rgba(255,255,255,.62);
  font-size: 12px;
  font-style: normal;
}

.cwqe-modal {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: none;
  padding: 142px 20px 28px;
}

.cwqe-modal.is-open {
  display: block;
}

.cwqe-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.62);
}

.cwqe-modal__card {
  position: relative;
  width: min(920px, calc(100vw - 40px));
  max-height: calc(100vh - 180px);
  margin: 0 auto;
  overflow: auto;
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 30px 80px rgba(0,0,0,.32);
}

.cwqe-modal__close {
  position: sticky;
  top: 12px;
  left: calc(100% - 56px);
  z-index: 2;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  background: var(--cwqe-red);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

.cwqe-product-detail {
  display: grid;
  grid-template-columns: minmax(240px, 38%) 1fr;
  gap: 30px;
  padding: 32px;
}

.cwqe-product-detail__image {
  display: grid;
  place-items: start center;
}

.cwqe-product-detail__image img {
  max-width: 100%;
  max-height: 380px;
  object-fit: contain;
}

.cwqe-product-detail__content h3 {
  margin: 0 0 10px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.05;
}

.cwqe-detail-short {
  color: #4b5563;
  font-weight: 700;
}

.cwqe-detail-description {
  color: #4b5563;
  line-height: 1.75;
}

.cwqe-detail-description ul {
  padding-left: 20px;
}

.cwqe-modal-loading {
  padding: 50px;
  font-size: 18px;
  font-weight: 900;
}

body.cwqe-modal-open {
  overflow: hidden;
}

@media (max-width: 980px) {
  .cwqe-hero,
  .cwqe-layout {
    grid-template-columns: 1fr;
  }

  .cwqe-app {
    padding: 18px;
  }

  .cwqe-summary {
    position: static;
    order: -1;
  }

  .cwqe-progress.is-sticky {
    margin-left: -18px;
    margin-right: -18px;
    padding-left: 18px;
    padding-right: 18px;
    top: var(--cwqe-sticky-top, var(--cwqe-scroll-offset, 96px));
  }

  .cwqe-product-detail {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .cwqe-hero {
    padding: 30px 22px;
  }

  .cwqe-count-grid,
  .cwqe-form-grid {
    grid-template-columns: 1fr 1fr;
  }

  .cwqe-card-grid {
    grid-template-columns: 1fr;
  }

  .cwqe-modal {
    padding-top: 90px;
  }

  .cwqe-modal__card {
    max-height: calc(100vh - 110px);
  }
}

.cwqe-btn:disabled,
.cwqe-btn[aria-disabled="true"] {
  opacity: .52;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

.cwqe-print-hint {
  margin: 10px 0 0;
  font-size: 12px;
  line-height: 1.45;
  color: var(--cwqe-muted);
}

.cwqe-print-hint.is-ready {
  color: #166534;
}


/* v2.0.2: wymagane dane klienta i czytelniejszy przycisk Druk / PDF */
.cwqe-required {
  color: var(--cwqe-red);
  font-weight: 900;
}

.cwqe-btn--print {
  width: 100%;
  margin-top: 8px;
  background: var(--cwqe-red);
  color: #fff !important;
  box-shadow: 0 16px 36px rgba(237,28,36,.28);
}

.cwqe-btn--print:hover {
  background: var(--cwqe-red-dark);
  color: #fff !important;
}

.cwqe-btn--print:disabled,
.cwqe-btn--print[aria-disabled="true"],
.cwqe-btn--print.is-disabled {
  opacity: 1 !important;
  background: #b81219 !important;
  color: #fff !important;
  cursor: not-allowed;
  box-shadow: none !important;
  transform: none !important;
}

.cwqe-print-hint.is-required {
  margin-top: 12px;
  padding: 11px 13px;
  border-radius: 14px;
  background: rgba(237,28,36,.96);
  color: #fff;
  font-weight: 900;
  line-height: 1.45;
}

.cwqe-print-hint.is-ready {
  color: #86efac;
  font-weight: 900;
}

.cwqe-map-field {
  margin-top: 18px;
}

.cwqe-map-field__label {
  display: block;
  font-weight: 700;
  margin-bottom: 6px;
}

.cwqe-map-field__hint {
  margin: 0 0 12px;
  font-size: 13px;
  color: #666;
}

.cwqe-map {
  position: relative;
  max-width: 560px;
  margin: 0 auto 14px;
  padding: 16px 14px 12px;
  background: linear-gradient(180deg, #fafafa 0%, #f0f0f0 100%);
  border-radius: 16px;
  border: 1px solid #d8d8d8;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.cwqe-map__badge {
  position: absolute;
  top: 10px;
  left: 50%;
  z-index: 2;
  transform: translateX(-50%);
  max-width: calc(100% - 24px);
  padding: 8px 16px;
  border-radius: 999px;
  background: #fff;
  border: 2px solid var(--cwqe-red);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
  pointer-events: none;
  text-align: center;
}

.cwqe-map__badge[hidden] {
  display: none !important;
}

.cwqe-map__badge-text {
  display: block;
  color: var(--cwqe-red-dark);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cwqe-map__svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.cwqe-map__path {
  fill: #ececec;
  stroke: #fff;
  stroke-width: 1.4;
  stroke-linejoin: round;
  stroke-linecap: round;
  cursor: pointer;
  transition: fill .15s ease, stroke .15s ease, filter .15s ease;
}

.cwqe-map__path.is-hover {
  fill: rgba(237, 28, 36, 0.22);
  stroke: var(--cwqe-red);
  stroke-width: 1.8;
  filter: drop-shadow(0 1px 2px rgba(237, 28, 36, 0.25));
}

.cwqe-map__path.is-selected {
  fill: var(--cwqe-red);
  stroke: #fff;
  stroke-width: 1.8;
  filter: drop-shadow(0 2px 4px rgba(237, 28, 36, 0.35));
}

.cwqe-map__path:focus-visible {
  outline: 3px solid var(--cwqe-red);
  outline-offset: 2px;
}

.cwqe-region-info {
  max-width: 560px;
  margin: 0 auto;
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(237, 28, 36, 0.08);
  border: 1px solid rgba(237, 28, 36, 0.25);
  text-align: center;
}

.cwqe-region-info[hidden] {
  display: none !important;
}

.cwqe-region-info strong {
  display: block;
  margin: 0 0 6px;
  color: var(--cwqe-red-dark);
  font-size: 16px;
}

.cwqe-region-info p {
  margin: 0;
  color: #333;
  font-size: 14px;
  line-height: 1.5;
}

.cwqe-region-info p[hidden] {
  display: none !important;
}

.cwqe-map-field.is-error .cwqe-map {
  border-color: var(--cwqe-red);
  box-shadow: 0 0 0 2px rgba(237, 28, 36, 0.15);
}

.cwqe-contact-form button[type="submit"]:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}
