/* Height Adjustable Range Section */
.klass-ha-section {
  --ha-ease: cubic-bezier(0.22, 1, 0.36, 1);
  background-color: #ECECEF;
  padding: 90px 20px;
}
.klass-ha-container {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: 70px;
  max-width: 1410px;
  margin: 0 auto;
  color: #333f48;
}

/* Left column: certificates above the clear-cut render */
.klass-ha-media {
  display: flex;
  flex-direction: column;
  gap: 30px;
}
/* The renders have wide transparent margins: crop to the desk (about 17-70% across, 12-80% down) */
.klass-ha-figure {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1.34;
}
.klass-ha-image {
  position: absolute;
  top: -13.16%;
  left: -32.1%;
  width: 188.7%;
  max-width: none;
  height: auto;
}

/* Content */
.klass-ha-content {
  max-width: 620px;
}
.klass-ha-section h2.content-title.klass-ha-title {
  line-height: 1.15;
  margin: 0 0 14px;
  padding: 0 !important;
}
/* "Range." always starts its own line */
.klass-ha-title-line {
  display: block;
}
.klass-ha-subtitle {
  margin: 0;
  font-size: 22px;
  font-weight: 600;
  line-height: 1.35;
  color: #333f48;
}
.klass-ha-body {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding-top: 32px;
}
.klass-ha-body p {
  margin: 0;
  font-size: 16px;
  line-height: 1.6;
  color: #333f48;
}

/* Button - plain, no animation */
.klass-ha-actions {
  padding-top: 36px;
}
.klass-ha-button {
  display: inline-flex;
  align-items: center;
  padding: 12px 26px;
  border-radius: 30px;
  --btn-bg: #00a7b5;
  --btn-color: #ffffff;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
}
.klass-ha-button:focus-visible {
  outline: 2px solid #94193B;
  outline-offset: 3px;
}

/* Certificates - matches the German engineering section */
.klass-ha-logos {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
}
.klass-ha-logo {
  display: block;
  width: auto;
  height: 80px;
}

/* Scroll-in reveal (classes added by reveal.js) */
.klass-ha-section.is-ready [data-klass-reveal] {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.9s var(--ha-ease), transform 0.9s var(--ha-ease);
}
.klass-ha-section.is-ready.is-visible [data-klass-reveal] {
  opacity: 1;
  transform: none;
}
.klass-ha-section.is-ready .klass-ha-title[data-klass-reveal] {
  transition-delay: 0.1s;
}
.klass-ha-section.is-ready .klass-ha-subtitle[data-klass-reveal] {
  transition-delay: 0.18s;
}
.klass-ha-section.is-ready .klass-ha-body[data-klass-reveal] {
  transition-delay: 0.26s;
}

/*
 * Features and Variants sit under Height Adjustable Range as one group:
 * plain h3 sub-headings, matching background and tighter spacing between the three sections.
 */
.klass-ha-section {
  padding-bottom: 40px;
}
.key-features-section#features {
  padding-top: 30px;
}
.product-range-section#range,
.klass-fixed-variants,
.klass-configurations-section {
  background-color: #ECECEF;
}

/* Fixed Range group (reuses the Height Adjustable Range layout) */
.klass-fixed-features {
  padding-top: 30px;
}
/* Variants close their group: no extra gap below the cards */
.product-range-section#range,
.klass-fixed-variants {
  padding-bottom: 70px;
}
.product-range-section#range .product-items-row,
.klass-fixed-variants .product-items-row,
.product-range-section#range .product-items-grid,
.klass-fixed-variants .product-items-grid {
  margin-bottom: 0;
}

/* Space (no line) between the Height Adjustable group, the Fixed group and Configurations.
   scroll-margin keeps #heightadjustablerange / #fixedrange links clear of the fixed site header. */
.klass-ha-section {
  scroll-margin-top: 140px;
}
.klass-ha-section.klass-fixed-section {
  padding-top: 70px;
}
.klass-configurations-section {
  padding-top: 50px;
}
.klass-ha-group-title {
  margin: 0 0 30px;
  padding: 0;
  font-size: 36px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: normal;
  text-transform: none;
  color: #333f48;
}

@media screen and (max-width: 1024px) {
  .product-range-section#range,
  .klass-fixed-variants {
    padding-bottom: 50px;
  }
  .klass-ha-section.klass-fixed-section {
    padding-top: 50px;
  }
  .klass-configurations-section {
    padding-top: 40px;
  }
}

/* Large Desktop (2561px+) */
@media screen and (min-width: 2561px) {
  .klass-ha-section {
    padding: 110px 20px 50px;
  }
  .klass-ha-group-title {
    font-size: 40px;
  }
  .klass-ha-content {
    max-width: 680px;
  }
  .klass-ha-body p {
    font-size: 18px;
  }
  .klass-ha-logo {
    height: 90px;
  }
}
/* Laptop (1025px - 1440px) */
@media screen and (min-width: 1025px) and (max-width: 1440px) {
  .klass-ha-section {
    padding: 80px 20px 36px;
  }
  .klass-ha-group-title {
    font-size: 32px;
    margin-bottom: 26px;
  }
  .klass-ha-container {
    gap: 56px;
  }
  .klass-ha-subtitle {
    font-size: 20px;
  }
  .klass-ha-body {
    gap: 20px;
    padding-top: 30px;
  }
  .klass-ha-actions {
    padding-top: 30px;
  }
  .klass-ha-logo {
    height: 72px;
  }
}
/* Tablet (768px - 1024px) */
@media screen and (min-width: 768px) and (max-width: 1024px) {
  .klass-ha-section {
    padding: 70px 15px 30px;
  }
  .klass-ha-group-title {
    font-size: 28px;
    margin-bottom: 22px;
  }
  .klass-ha-container {
    gap: 36px;
  }
  .klass-ha-subtitle {
    font-size: 18px;
  }
  .klass-ha-body {
    gap: 16px;
    padding-top: 24px;
  }
  .klass-ha-body p {
    font-size: 14px;
    line-height: 1.6;
  }
  .klass-ha-actions {
    padding-top: 26px;
  }
  .klass-ha-button {
    font-size: 14px;
    padding: 11px 22px;
  }
  .klass-ha-media {
    gap: 22px;
  }
  .klass-ha-logos {
    gap: 14px;
  }
  .klass-ha-logo {
    height: 60px;
  }
}
/* Mobile (767px and below) - image on top, text below */
@media screen and (max-width: 767px) {
  .klass-ha-section {
    padding: 60px 15px 24px;
  }
  .key-features-section#features {
    padding-top: 20px;
  }
  .klass-ha-group-title {
    font-size: 24px;
    margin-bottom: 18px;
  }
  .klass-ha-container {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }
  .klass-ha-content {
    max-width: 100%;
  }
  .klass-ha-subtitle {
    font-size: 17px;
  }
  .klass-ha-body {
    gap: 14px;
    padding-top: 20px;
  }
  .klass-ha-body p {
    font-size: 14px;
    line-height: 1.6;
  }
  .klass-ha-actions {
    padding-top: 24px;
  }
  .klass-ha-button {
    font-size: 14px;
    padding: 11px 22px;
  }
  .klass-ha-media {
    gap: 18px;
  }
  .klass-ha-logos {
    gap: 12px;
  }
  .klass-ha-logo {
    height: 56px;
  }
}

/* Klass Range Product Specification - semantic table (kept fully visible for search and AI readers) */
.klass-spec-section {
  background-color: #ECECEF;
  padding: 60px 20px 70px;
  /* Keeps /klass/#specifications links clear of the fixed site header */
  scroll-margin-top: 140px;
}
.klass-spec-container {
  max-width: 1410px;
  margin: 0 auto;
  color: #333f48;
}
.klass-spec-section h2.content-title.klass-spec-title {
  line-height: 1.15;
  margin: 0 0 24px;
  padding: 0 !important;
}
.klass-spec-caption {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.klass-spec-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 16px;
  line-height: 1.6;
  color: #333f48;
}
.klass-spec-table thead th {
  color:#ffffff;
  background: #333f48;
  padding: 18px 20px;
  font-size: 16px;
  font-weight: 600;
  text-align: left;
}
.klass-spec-table thead th:first-child {
  border-radius: 18px 0 0 0;
}
.klass-spec-table thead th:last-child {
  border-radius: 0 18px 0 0;
}
.klass-spec-table tbody th,
.klass-spec-table tbody td {
  padding: 14px 20px;
  text-align: left;
  vertical-align: top;
}
.klass-spec-table tbody th {
  width: 30%;
  font-weight: 600;
}
.klass-spec-table tbody td {
  font-weight: 400;
}
.klass-spec-table tbody tr:last-child th,
.klass-spec-table tbody tr:last-child td {
  border-bottom: none;
}
/* Plain white body with no row lines. The theme adds zebra stripes and borders to table rows,
   so these selectors are deliberately specific enough to override them. */
.klass-spec-section .klass-spec-table tbody tr:nth-child(n),
.klass-spec-section .klass-spec-table tbody tr:nth-child(n) th,
.klass-spec-section .klass-spec-table tbody tr:nth-child(n) td {
  background: #ffffff;
  border: none;
}
/* Round the table's bottom corners (Warranty / 10 years). The table also clips to its
   radius, in case the theme paints the zebra row colour on the <tr> rather than the cells. */
.klass-spec-table {
  border-radius: 18px;
  overflow: hidden;
}
.klass-spec-table tbody tr:last-child th {
  border-radius: 0 0 0 18px;
}
.klass-spec-table tbody tr:last-child td {
  border-radius: 0 0 18px 0;
}
.klass-configurations-section {
  padding-top: 0;
  padding-bottom: 70px;
}
@media screen and (min-width: 2561px) {
  .klass-spec-table {
    font-size: 18px;
  }
}
@media screen and (max-width: 1024px) {
  .klass-spec-section {
    padding: 40px 15px 50px;
  }
  .klass-spec-table {
    font-size: 15px;
  }
  .klass-spec-table thead th {
    padding: 16px;
    font-size: 15px;
  }
  .klass-spec-table tbody th,
  .klass-spec-table tbody td {
    padding: 12px 16px;
  }
}
/* Phones: each row stacks, label above value */
@media screen and (max-width: 600px) {
  .klass-spec-table thead {
    display: none;
  }
  .klass-spec-table,
  .klass-spec-table tbody,
  .klass-spec-table tr,
  .klass-spec-table tbody th,
  .klass-spec-table tbody td {
    display: block;
    width: 100%;
  }
  .klass-spec-section .klass-spec-table tbody tr:nth-child(n) {
    padding: 12px 22px;
  }
  .klass-spec-table tbody tr:last-child {
    border-bottom: none;
  }
  .klass-spec-table tbody tr:last-child th,
  .klass-spec-table tbody tr:last-child td {
    border-radius: 0;
  }
  /* White card with the same 18px corners as the desktop table, plus room at the top and bottom */
  .klass-spec-table {
    padding: 12px 0;
    border-radius: 18px;
    overflow: hidden;
    background: #ffffff;
  }
  /* The theme gives table bodies a faint top/bottom border */
  .klass-spec-section .klass-spec-table tbody {
    border: none;
    background: #ffffff;
  }
  .klass-spec-table tbody th,
  .klass-spec-table tbody td {
    padding: 0;
    border-bottom: none;
  }
  .klass-spec-table tbody th {
    margin-bottom: 2px;
  }
}

/* Configurations - one diagram in a white card, styled like the Variants cards */
.klass-config-card {
  display: block;
  padding: 40px 36px;
  border-radius: 24px;
  background: #ffffff;
  pointer-events: none; /* desktop: diagram is already readable, nothing to open */
  cursor: default;
}
.klass-config-image {
  display: block;
  width: 100%;
  height: auto;
}
.klass-config-hint {
  display: none;
}
@media screen and (max-width: 1024px) {
  .klass-config-card {
    position: relative;
    padding: 28px 20px 44px;
    pointer-events: auto;
    cursor: zoom-in;
  }
  .klass-config-hint {
    display: block;
    position: absolute;
    left: 0;
    right: 0;
    bottom: 14px;
    font-size: 12px;
    color: #8a8f93;
    text-align: center;
  }
}

/* Full-size diagram viewer (tablet and smaller) */
.klass-config-dialog {
  /* margin:auto centres the dialog; the page's global "* { margin: 0 }" reset would pin it to the top */
  margin: auto;
  width: min(96vw, 1400px);
  max-width: none;
  padding: 0;
  border: none;
  border-radius: 24px;
  background: #ffffff;
  color: #333f48;
}
.klass-config-dialog::backdrop {
  background: rgba(51, 63, 72, 0.6);
}
.klass-config-dialog-body {
  overflow-x: auto;
  padding: 56px 24px 28px;
  -webkit-overflow-scrolling: touch;
}
.klass-config-dialog-body img {
  display: block;
  width: auto;
  max-width: none;
  height: 130px;
}
.klass-config-dialog-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: #ECECEF;
  color: #333f48;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}
.klass-config-dialog-hint {
  margin: 0;
  padding: 0 24px 20px;
  font-size: 12px;
  color: #8a8f93;
}

/* Contact & Support - text and button on the left, certificates bottom-right in line with the button */
.klass-contact-section {
  padding: 80px 20px 90px;
}
.klass-contact-container {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  max-width: 1410px;
  margin: 0 auto;
  color: #333f48;
}
.klass-contact-text {
  max-width: 900px;
}
.klass-contact-section h2.content-title.klass-contact-title {
  line-height: 1.15;
  margin: 0 0 36px;
  padding: 0 !important;
  color: #333f48;
}
.klass-contact-lead {
  margin: 0 0 30px;
  font-size: 22px;
  font-weight: 500;
  line-height: 1.4;
  color: #00a7b5;
}
.klass-contact-body {
  margin: 0 0 36px;
  font-size: 18px;
  line-height: 1.9;
  color: #333f48;
}
.klass-contact-button {
  display: inline-flex;
  align-items: center;
  padding: 16px 44px;
  border-radius: 30px;
  --btn-bg: #00a7b5;
  --btn-color: #ffffff;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
}
.klass-contact-button:focus-visible {
  outline: 2px solid #94193B;
  outline-offset: 3px;
}
.klass-contact-logos {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 22px;
  flex-shrink: 0;
}
.klass-contact-logo {
  display: block;
  width: auto;
  height: 104px;
}
@media screen and (min-width: 2561px) {
  .klass-contact-lead {
    font-size: 26px;
  }
  .klass-contact-body {
    font-size: 20px;
  }
  .klass-contact-logo {
    height: 116px;
  }
}
@media screen and (min-width: 1025px) and (max-width: 1440px) {
  .klass-contact-section {
    padding: 70px 20px 80px;
  }
  .klass-contact-lead {
    font-size: 20px;
  }
  .klass-contact-body {
    font-size: 16px;
  }
  .klass-contact-logo {
    height: 84px;
  }
  .klass-contact-logos {
    gap: 18px;
  }
}
/* Tablet and smaller: certificates move under the button */
@media screen and (max-width: 1024px) {
  .klass-contact-section {
    padding: 60px 15px 70px;
  }
  .klass-contact-container {
    flex-direction: column;
    align-items: flex-start;
    gap: 36px;
  }
  .klass-contact-section h2.content-title.klass-contact-title {
    margin-bottom: 24px;
  }
  .klass-contact-lead {
    margin-bottom: 20px;
    font-size: 18px;
  }
  .klass-contact-body {
    margin-bottom: 28px;
    font-size: 15px;
    line-height: 1.8;
  }
  .klass-contact-button {
    padding: 14px 36px;
    font-size: 15px;
  }
  .klass-contact-logo {
    height: 72px;
  }
  .klass-contact-logos {
    gap: 16px;
  }
}
@media screen and (max-width: 767px) {
  .klass-contact-section {
    padding: 50px 15px 60px;
  }
  .klass-contact-lead {
    font-size: 16px;
  }
  .klass-contact-body {
    font-size: 14px;
  }
  .klass-contact-body br {
    display: none;
  }
  .klass-contact-logo {
    height: 58px;
  }
  .klass-contact-logos {
    gap: 12px;
  }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .klass-ha-section *,
  .klass-ha-section.is-ready [data-klass-reveal] {
    transition: none !important;
    transform: none !important;
  }
}
