:root {
  --serafi-navy: #102541;
  --serafi-blue: #23255a;
  --serafi-gold: #E46C0A;
  --serafi-text: #22313f;
  --serafi-muted: #667789;
  --serafi-border: rgba(16, 37, 65, 0.12);
  --serafi-container: 1200px;
}

.serafi-products-page {
  color: var(--serafi-text);
  background: #fff;
}

.serafi-products-page *,
.serafi-products-page *::before,
.serafi-products-page *::after {
  box-sizing: border-box;
}

.serafi-products-page img {
  display: block;
  max-width: 100%;
}

.serafi-products-page a {
  color: inherit;
  text-decoration: none;
}

.serafi-products-page p {
  margin: 0 0 1rem;
  color: var(--serafi-muted);
  line-height: 1.7;
}

.serafi-products-page h1,
.serafi-products-page h2,
.serafi-products-page h3 {
  margin: 0 0 1rem;
  color: var(--serafi-navy);
  line-height: 1.15;
}

.serafi-products-page .container {
  width: min(calc(100% - 32px), var(--serafi-container));
  margin: 0 auto;
}

.template-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  color: var(--serafi-gold);
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.template-kicker::before {
  content: "";
  width: 18px;
  height: 2px;
  background: currentColor;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 12px 22px;
  border: 0;
  border-radius: 8px;
  font-weight: 700;
  cursor: pointer;
}

.button--primary {
  background: var(--serafi-gold);
  color: #fff;
}

.products-page-hero {
  position: relative;
  overflow: hidden;
  padding: 96px 0 80px;
  background: #0d1217;
}

.products-page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 80% at 80% 50%, rgba(228, 108, 10, .13) 0%, transparent 70%);
  pointer-events: none;
}

.products-page-hero__inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}

.products-page-hero .template-kicker {
  padding: 5px 12px;
  border: 1px solid rgba(228, 108, 10, .25);
  background: rgba(228, 108, 10, .12);
}

.products-page-hero h1 {
  margin: 12px 0 16px;
  color: #fff;
  font-size: clamp(1.9rem, 3.5vw, 2.8rem);
}

.products-page-hero p {
  max-width: 620px;
  margin: 0;
  color: rgba(255, 255, 255, .68);
  font-size: 1.05rem;
}

.products-page-hero__meta {
  flex-shrink: 0;
}

.products-page-hero__count {
  display: flex;
  width: 120px;
  height: 120px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 2px;
  border: 2px solid rgba(228, 108, 10, .4);
  border-radius: 50%;
  background: rgba(228, 108, 10, .08);
  text-align: center;
}

.products-page-hero__count strong {
  color: var(--serafi-gold);
  font-size: 2rem;
  line-height: 1;
}

.products-page-hero__count span {
  color: rgba(255, 255, 255, .55);
  font-size: .75rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.products-filter-bar {
  position: sticky;
  top: 0;
  z-index: 90;
  border-bottom: 1px solid var(--serafi-border);
  background: #fff;
  box-shadow: 0 2px 12px rgba(16, 37, 65, .06);
}

.products-filter-bar__inner {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.products-filter-bar__inner::-webkit-scrollbar {
  display: none;
}

.pfb-btn {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  gap: 6px;
  padding: 7px 18px;
  border: 1.5px solid var(--serafi-border);
  border-radius: 100px;
  background: transparent;
  color: var(--serafi-text);
  font-size: .875rem;
  font-weight: 500;
  white-space: nowrap;
  transition: border-color .2s ease, color .2s ease, background .2s ease;
}

.pfb-btn:hover {
  border-color: var(--serafi-gold);
  color: var(--serafi-gold);
}

.pfb-btn.is-active {
  border-color: var(--serafi-gold);
  background: var(--serafi-gold);
  color: #fff;
}

.pfb-btn__count {
  display: inline-flex;
  min-width: 20px;
  height: 20px;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  border-radius: 100px;
  background: rgba(16, 37, 65, .1);
  font-size: .72rem;
  font-weight: 600;
  line-height: 1;
}

.pfb-btn.is-active .pfb-btn__count {
  background: rgba(255, 255, 255, .25);
  color: #fff;
}

.products-grid-section {
  padding: 64px 0 80px;
  background: #f8f9fb;
}

.products-catalog-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
}

.products-active-filter {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 32px;
  padding: 12px 20px;
  border: 1px solid var(--serafi-border);
  border-radius: 10px;
  background: #fff;
  font-size: .9rem;
}

.products-active-filter strong,
.products-active-filter a:hover {
  color: var(--serafi-gold);
}

.products-active-filter a {
  color: var(--serafi-muted);
  font-size: .85rem;
}

.product-card--boxed {
  overflow: hidden;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 2px 12px rgba(16, 37, 65, .07);
  text-align: left;
  transition: box-shadow .25s ease, transform .25s ease;
}

.product-card--boxed:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(16, 37, 65, .13);
}

.product-card__image--boxed {
  display: block;
  padding: 38px 34px;
  background: #fff;
}

.product-card__image--boxed img {
  width: 100%;
  aspect-ratio: 1 / .8;
  object-fit: contain;
  transition: transform .35s ease;
}

.product-card:hover .product-card__image--boxed img {
  transform: scale(1.05);
}

.product-card__footer,
.product-page-related__footer {
  display: grid;
  grid-template-columns: 60px 1fr;
  align-items: stretch;
  min-height: 62px;
  color: var(--serafi-text);
}

.product-card__arrow,
.product-page-related__arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--serafi-gold);
  color: #fff;
  font-size: 1.7rem;
  line-height: 1;
}

.product-card__footer-copy,
.product-page-related__card h3 {
  position: relative;
  z-index: 0;
  overflow: hidden;
  padding: 14px 16px 12px;
  background: #fff;
}

.product-card__footer-copy::before,
.product-page-related__card h3::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--serafi-gold);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .32s ease;
}

.product-card__footer-copy h3,
.product-page-related__card h3 {
  margin: 0;
  color: var(--serafi-text);
  font-size: 1rem;
  line-height: 1.35;
  transition: color .3s ease;
}

.product-card__footer:hover .product-card__footer-copy::before,
.product-page-related__footer:hover h3::before {
  transform: scaleX(1);
}

.product-card__footer:hover h3,
.product-page-related__footer:hover h3 {
  color: #fff;
}

.products-pagination {
  display: flex;
  justify-content: center;
  margin-top: 48px;
}

.products-pagination .nav-links,
.products-pagination ul.page-numbers {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.products-pagination .page-numbers,
.products-pagination .nav-links a,
.products-pagination .nav-links span {
  display: inline-flex;
  min-width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  border: 1.5px solid var(--serafi-border);
  border-radius: 8px;
  color: var(--serafi-text);
  font-size: .9rem;
}

.products-pagination .page-numbers:hover,
.products-pagination .page-numbers.current,
.products-pagination .nav-links a:hover,
.products-pagination .nav-links span.current {
  border-color: var(--serafi-gold);
  background: var(--serafi-gold);
  color: #fff;
}

.products-empty {
  padding: 80px 20px;
  text-align: center;
}

.product-page-main {
  padding: 22px 0 34px;
  background: #fff;
}

.product-showcase {
  display: grid;
  grid-template-columns: 1.02fr 1.06fr .92fr;
  border-top: 1px solid rgba(36, 51, 68, .08);
  border-left: 1px solid rgba(36, 51, 68, .08);
}

.product-showcase__cell {
  min-height: 0;
  border-right: 1px solid rgba(36, 51, 68, .08);
  border-bottom: 1px solid rgba(36, 51, 68, .08);
  background: #fff;
}

.product-showcase__cell--image,
.product-showcase__cell--summary,
.product-showcase__cell--actions {
  display: flex;
}

.product-showcase__cell--image {
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
}

.product-showcase__cell--image img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
}

.product-lightbox-trigger {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
}

.product-showcase__cell--summary {
  align-items: center;
  padding: 14px 20px;
}

.product-showcase__summary-wrap {
  width: 100%;
  max-width: 320px;
}

.product-showcase__summary-wrap h2 {
  margin-bottom: 10px;
  font-size: clamp(1.45rem, 1.9vw, 1.8rem);
}

.product-showcase__stock {
  margin-bottom: 10px;
  color: #6f7b88;
  font-size: .85rem;
}

.product-showcase__stock span {
  color: var(--serafi-gold);
  font-weight: 700;
}

.product-page-main__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.product-page-main__meta span {
  padding: 6px 10px;
  border-left: 3px solid var(--serafi-gold);
  border-radius: 4px;
  background: #f5f5f2;
  color: #334550;
  font-size: .8rem;
}

.product-page-main__excerpt--plain {
  max-height: 110px;
  overflow: hidden;
  color: #64707b;
  font-size: .88rem;
  line-height: 1.55;
}

.product-showcase__cell--actions {
  flex-direction: column;
  justify-content: center;
  padding: 14px 16px;
}

.product-showcase__actions {
  display: grid;
  gap: 8px;
  width: 100%;
}

.product-action-button {
  display: flex;
  width: 100%;
  min-height: 40px;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border: 0;
  border-radius: 8px;
  color: #fff !important;
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease;
}

.product-action-button::after {
  content: "\2192";
  font-size: 1rem;
}

.product-action-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(18, 24, 38, .12);
}

.product-action-button.is-static {
  cursor: default;
}

.product-action-button.is-static:hover {
  transform: none;
  box-shadow: none;
}

.product-action-button--primary,
.product-action-button--secondary {
  background: var(--serafi-blue);
}

.product-action-button--accent {
  background: var(--serafi-gold);
}

.contact-form-status {
  margin-bottom: 20px;
  padding: 14px 16px;
  border-left: 4px solid var(--serafi-gold);
  background: #fff6ef;
  color: #7d3d09;
  font-weight: 600;
}

.contact-form-status.is-success {
  border-left-color: #2f7d32;
  background: #effaf0;
  color: #215b24;
}

.contact-form-status.is-error {
  border-left-color: #b93a2a;
  background: #fff2f0;
  color: #8b2a1f;
}

.product-request-status {
  margin-top: 18px;
}

.product-technical-specs {
  padding: 18px 0 30px;
  background: #f1f0f0;
}

.product-technical-specs__grid {
  display: grid;
  grid-template-columns: 1.8fr 1.2fr;
  border-top: 1px solid rgba(36, 51, 68, .08);
  border-left: 1px solid rgba(36, 51, 68, .08);
}

.product-technical-specs__content,
.product-technical-specs__drawing {
  min-height: 320px;
  border-right: 1px solid rgba(36, 51, 68, .08);
  border-bottom: 1px solid rgba(36, 51, 68, .08);
  background: #fff;
}

.product-technical-specs__content {
  padding: 54px 40px;
}

.product-technical-specs__content h2 {
  margin-bottom: 28px;
  color: #1f2a60;
  font-size: clamp(1.33rem, 1.7vw, 1.7rem);
}

.product-specs-table-wrap {
  overflow-x: auto;
}

.product-specs-table {
  width: 100%;
  min-width: 840px;
  border-collapse: collapse;
}

.product-specs-table th,
.product-specs-table td {
  padding: 18px 20px;
  text-align: left;
}

.product-specs-table th {
  background: #31338f;
  color: #fff;
  font-size: .8rem;
  font-weight: 700;
}

.product-specs-table td {
  border-bottom: 1px solid rgba(36, 51, 68, .08);
  background: #fff;
  color: #5c6c79;
}

.product-technical-specs__drawing {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 34px 26px;
}

.product-technical-specs__drawing img {
  width: 100%;
  max-width: 330px;
  object-fit: contain;
}

.product-page-description {
  padding: 34px 0 30px;
  background: #fff;
}

.product-page-description__tab {
  width: fit-content;
  margin: 0 auto 24px;
  padding: 0 18px 10px;
  border-bottom: 3px solid var(--serafi-gold);
  font-size: 1rem;
  font-weight: 700;
}

.product-page-description__content {
  max-width: 980px;
  margin: 0 auto;
  color: #5f707c;
}

.product-page-related {
  padding: 22px 0 90px;
  background: #fff;
}

.product-page-related h2 {
  margin-bottom: 24px;
  color: var(--serafi-gold);
  font-size: 1.5rem;
  font-weight: 800;
  text-transform: uppercase;
}

.product-page-related__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.product-page-related__card {
  overflow: hidden;
  border: 1px solid rgba(36, 51, 68, .08);
  background: #fff;
}

.product-page-related__image {
  display: block;
  padding: 54px 48px;
  background: #fff;
}

.product-page-related__image img {
  width: 100%;
  aspect-ratio: 1 / .8;
  object-fit: contain;
}

.contact-form__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.contact-field {
  display: grid;
  gap: 8px;
}

.contact-field label {
  color: var(--serafi-text);
  font-size: .95rem;
  font-weight: 700;
}

.contact-field input,
.contact-field textarea {
  width: 100%;
  padding: 15px 16px;
  border: 1px solid rgba(34, 49, 63, .14);
  border-radius: 0;
  background: #fbfbfa;
  color: var(--serafi-text);
  font: inherit;
}

.contact-field input:focus,
.contact-field textarea:focus {
  outline: none;
  border-color: var(--serafi-gold);
  background: #fff;
}

.contact-field--full {
  grid-column: 1 / -1;
}

.contact-form__submit {
  margin-top: 20px;
  min-width: 210px;
}

.serafi-popup,
.serafi-lightbox {
  position: fixed;
  inset: 0;
  display: none;
}

.serafi-popup {
  z-index: 120;
}

.serafi-lightbox {
  z-index: 130;
}

.serafi-popup.is-open,
.serafi-lightbox.is-open {
  display: block;
}

.serafi-popup__backdrop,
.serafi-lightbox__backdrop {
  position: absolute;
  inset: 0;
}

.serafi-popup__backdrop {
  background: rgba(18, 24, 28, .7);
}

.serafi-lightbox__backdrop {
  background: rgba(13, 16, 22, .82);
}

.serafi-popup__dialog {
  position: relative;
  width: min(680px, calc(100% - 24px));
  margin: 60px auto;
  background: #fff;
  box-shadow: 0 28px 54px rgba(8, 12, 14, .28);
}

.serafi-popup__close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 40px;
  height: 40px;
  border: 0;
  background: #f3f3f1;
  color: var(--serafi-text);
  font-size: 1.7rem;
  line-height: 1;
  cursor: pointer;
}

.serafi-popup__content {
  padding: 34px;
}

.serafi-lightbox__dialog {
  position: relative;
  display: flex;
  width: min(980px, calc(100% - 32px));
  min-height: calc(100vh - 80px);
  align-items: center;
  justify-content: center;
  margin: 40px auto;
}

.serafi-lightbox__image {
  max-width: 100%;
  max-height: calc(100vh - 120px);
  background: #fff;
  box-shadow: 0 28px 60px rgba(0, 0, 0, .34);
}

.serafi-lightbox__close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .12);
  color: #fff;
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
}

body.popup-is-open {
  overflow: hidden;
}

@media (max-width: 1100px) {
  .products-catalog-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 991px) {
  .product-showcase,
  .product-technical-specs__grid,
  .product-page-related__grid {
    grid-template-columns: 1fr;
  }

  .product-showcase__cell--summary,
  .product-showcase__cell--image,
  .product-showcase__cell--actions {
    padding: 28px 22px;
  }

  .contact-form__grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {
  .products-page-hero {
    padding: 64px 0 56px;
  }

  .products-page-hero__inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 32px;
  }

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

  .products-active-filter {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .product-technical-specs__content {
    padding: 34px 22px;
  }

  .serafi-popup__dialog {
    margin: 24px auto;
  }

  .serafi-popup__content {
    padding: 24px;
  }
}

@media (max-width: 480px) {
  .products-catalog-grid {
    grid-template-columns: 1fr;
  }
}
