.page-tapered {
  #main-content {
    background: #fff;
  }

  #main-content > section {
    padding: 0 0 6rem;
  }

  #main-content > section:first-of-type {
    padding-bottom: 0;
  }

  #ts-hero.cat-banner {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    margin-bottom: 0 !important;
  }

  #ts-hero .banner-image {
    background: transparent;
    overflow: hidden;
  }

  #ts-hero .banner-image img {
    width: 108%;
    height: 100%;
    max-width: none;
    object-fit: contain;
    object-position: right center;
    display: block;
  }

  #ts-hero-note {
    position: absolute;
    top: 2rem;
    right: 0;
    color: #ff0000;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    line-height: 1.35;
    text-transform: uppercase;
    text-align: right;
  }

  #ts-series-grid.product-grid,
  #ts-protocol-grid.product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  #ts-prosthetic-grid.product-grid,
  #ts-detail-grid.product-grid,
  #ts-tools-grid.product-grid,
  #ts-clinical-grid.product-grid,
  #ts-cases-grid.product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #ts-benefits-grid.product-grid,
  #ts-performance-grid.product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  #ts-prosthetic-grid.product-grid {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: calc((100% - 4rem) / 3);
    overflow-x: auto;
    overflow-y: hidden;
    padding-block: 1rem;
    margin-block: -1rem;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    overscroll-behavior-inline: contain;
  }

  #ts-prosthetic-grid.product-grid::-webkit-scrollbar {
    display: none;
  }

  #ts-prosthetic-grid .product-card {
    min-width: 0;
    height: 100%;
    scroll-snap-align: start;
  }

  #ts-prosthetic-grid .product-card {
    padding: 1.5rem 1.25rem;
  }

  #ts-prosthetic-grid .card-figure {
    height: 220px;
    min-height: 220px;
    margin-top: auto;
  }

  #ts-prosthetic-grid .card-figure img {
    width: 100%;
    height: 100%;
    max-height: 220px;
    object-fit: contain;
    object-position: center;
  }

  .ts-prosthetic-slider {
    overflow: visible;
  }

  .ts-prosthetic-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1.5rem;
  }

  .ts-slider-controls {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
  }

  .ts-slider-button {
    width: 44px;
    height: 44px;
    border: 1px solid #e6e6e6;
    border-radius: 50%;
    background: #fff;
    color: #ff0000;
    font-size: 1.25rem;
    cursor: pointer;
    transition: border-color 200ms ease, background-color 200ms ease, color 200ms ease;
  }

  .ts-slider-button:hover,
  .ts-slider-button:focus-visible {
    border-color: #ff0000;
    background: #ff0000;
    color: #fff;
  }

  #ts-series-grid .product-card,
  #ts-benefits-grid .product-card,
  #ts-performance-grid .product-card,
  #ts-cases-grid .product-card,
  #ts-prosthetic-grid .product-card,
  #ts-detail-grid .product-card,
  #ts-tools-grid .product-card,
  #ts-protocol-grid .product-card,
  #ts-clinical-grid .product-card {
    align-items: flex-start;
    text-align: left;
    padding: 2rem 1.5rem;
    gap: 1rem;
  }

  #ts-series-grid .product-card,
  #ts-benefits-grid .product-card,
  #ts-performance-grid .product-card {
    text-decoration: none;
  }

  #ts-series-grid .card-figure,
  #ts-benefits-grid .card-figure,
  #ts-performance-grid .card-figure,
  #ts-prosthetic-grid .card-figure,
  #ts-detail-grid .card-figure,
  #ts-tools-grid .card-figure,
  #ts-protocol-grid .card-figure,
  #ts-clinical-grid .card-figure {
    width: 100%;
    height: auto;
    min-height: 180px;
    margin-bottom: 0;
  }

  #ts-cases-grid .card-figure {
    display: none;
  }

  #ts-series-grid .card-figure img,
  #ts-benefits-grid .card-figure img,
  #ts-performance-grid .card-figure img,
  #ts-prosthetic-grid .card-figure img,
  #ts-detail-grid .card-figure img,
  #ts-tools-grid .card-figure img,
  #ts-protocol-grid .card-figure img,
  #ts-clinical-grid .card-figure img {
    width: 100%;
    max-width: 100%;
    max-height: 280px;
    object-fit: contain;
  }

  #ts-series-grid .product-card > span:first-child,
  #ts-series-grid .product-card > p.section-label:first-child {
    margin-bottom: 0;
  }

  .card-info {
    width: 100%;
  }

  .product-card figure {
    width: 100%;
    margin: 0;
  }

  .product-card ul {
    margin: 0;
    padding-left: 1.2rem;
    color: #666;
  }

  .product-card li + li {
    margin-top: 0.45rem;
  }

  .card-info h3,
  .card-info .section-title {
    font-size: var(--fs-h3);
    line-height: var(--lh-h3);
    margin-bottom: 0.65rem;
    color: #121212;
  }

  .card-info .section-title {
    font-size: var(--fs-h3);
  }

  .card-info p {
    margin-bottom: 0.75rem;
  }

  #main-content .category-section-title {
    font-size: var(--fs-h2);
    line-height: var(--lh-h2);
    margin-bottom: 1.5rem;
    color: #121212 !important;
  }

  #main-content .section-label {
    font-size: var(--fs-small);
    letter-spacing: 0.16em;
  }

  .card-info > a:last-child:not(.btn),
  .card-info > span:last-child {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--prod-blue);
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 3px;
  }

  #ts-series-grid .card-info > span:last-child::after,
  #ts-benefits-grid .card-info > span:last-child::after,
  #ts-performance-grid .card-info > span:last-child::after {
    content: "→";
  }

  #ts-benefits-grid,
  #ts-performance-grid {
    margin-top: 2rem;
    margin-bottom: 6rem;
  }

  #ts-performance-grid {
    margin-top: 4rem;
    margin-bottom: 0;
  }

  .ts-clinical-solutions__layout {
    display: grid;
    grid-template-columns: minmax(280px, 0.75fr) minmax(0, 1.25fr);
    gap: clamp(3rem, 7vw, 8rem);
  }

  .ts-clinical-solutions__intro {
    min-width: 0;
  }

  .ts-clinical-solutions__media {
    margin-top: 1.5rem;
  }

  .ts-clinical-solutions__media figure {
    display: grid;
    aspect-ratio: 1;
    margin: 0;
    place-items: center;
    background: #fff;
  }

  .ts-clinical-solutions__media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
  }

  .ts-clinical-solutions__content {
    min-width: 0;
    padding-top: clamp(3rem, 6vw, 6.5rem);
  }

  .ts-clinical-solutions__item {
    display: grid;
    grid-template-columns: minmax(180px, 0.7fr) minmax(0, 1.3fr);
    gap: clamp(1.5rem, 3vw, 3rem);
    padding: 1.5rem 0;
    border-top: 1px solid #d8dde6;
  }

  .ts-clinical-solutions__item:last-child {
    border-bottom: 1px solid #d8dde6;
  }

  .ts-clinical-solutions__item h3,
  .ts-clinical-solutions__item p {
    margin: 0;
  }

  .ts-clinical-solutions__item h3 {
    color: var(--prod-blue, #214ecd);
    font-size: 1.1rem;
    line-height: 1.35;
  }

  #ts-benefits-grid .product-card,
  #ts-performance-grid .product-card {
    min-height: 100%;
    padding: 1.5rem;
  }

  #ts-benefits-grid .ts-feature-item,
  #ts-performance-grid .ts-feature-item {
    padding: 1.25rem 0 0;
    border: 0;
    border-top: 1px solid #d8dde6;
    background: transparent;
    box-shadow: none;
  }

  #ts-benefits-grid .ts-feature-item:hover,
  #ts-performance-grid .ts-feature-item:hover {
    border-color: #d8dde6;
    box-shadow: none;
    transform: none;
  }

  #ts-benefits-grid .ts-deep-link-card,
  #ts-performance-grid .ts-deep-link-card {
    grid-column: 1 / -1;
    min-height: 0;
    padding: 1.25rem 1.5rem;
    border-color: rgba(255, 0, 0, 0.28);
    background: #fff;
  }

  #ts-benefits-grid .ts-deep-link-card .card-info,
  #ts-performance-grid .ts-deep-link-card .card-info {
    display: grid;
    grid-template-columns: minmax(220px, 0.8fr) minmax(280px, 1.4fr) auto;
    grid-template-rows: auto auto;
    align-items: center;
    column-gap: 2rem;
  }

  #ts-benefits-grid .ts-deep-link-card .section-label,
  #ts-performance-grid .ts-deep-link-card .section-label {
    grid-column: 1;
    grid-row: 1;
    margin: 0 0 0.3rem;
  }

  #ts-benefits-grid .ts-deep-link-card h3,
  #ts-performance-grid .ts-deep-link-card h3 {
    grid-column: 1;
    grid-row: 2;
    margin: 0;
  }

  #ts-benefits-grid .ts-deep-link-card p:not(.section-label),
  #ts-performance-grid .ts-deep-link-card p:not(.section-label) {
    grid-column: 2;
    grid-row: 1 / span 2;
    margin: 0;
  }

  #ts-benefits-grid .ts-deep-link-card span,
  #ts-performance-grid .ts-deep-link-card span {
    grid-column: 3;
    grid-row: 1 / span 2;
    white-space: nowrap;
  }

  #ts-benefits-grid .card-figure,
  #ts-performance-grid .card-figure {
    min-height: 140px;
    align-items: center;
  }

  #ts-benefits-grid .card-info,
  #ts-performance-grid .card-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
  }

  #ts-benefits-grid .card-info > span:last-child,
  #ts-performance-grid .card-info > span:last-child {
    margin-top: auto;
  }

  #ts-benefits-grid .card-info h3,
  #ts-performance-grid .card-info h3 {
    font-size: 1rem;
    line-height: 1.15;
    margin-bottom: 0.6rem;
  }

  #ts-benefits-grid .card-info p,
  #ts-performance-grid .card-info p {
    line-height: 1.5;
    margin-bottom: 0.5rem;
  }

  #ts-benefits-grid .card-figure img,
  #ts-performance-grid .card-figure img {
    max-height: 150px;
  }

  #ts-cases-grid .product-card {
    min-height: 100%;
    padding: 2.25rem 2rem;
  }

  #ts-cases-grid .card-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    height: 100%;
  }

  #ts-cases-grid .card-info .btn {
    margin-top: auto;
    align-self: flex-start;
    text-decoration: none;
    color: #fff !important;
  }

  #ts-cases-grid .card-info .btn:hover,
  #ts-cases-grid .card-info .btn:focus {
    color: #fff !important;
  }

  #ts-workflow-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.5rem;
  }

  #ts-workflow-grid img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border: 1px solid #e6e6e6;
  }

  #ts-workflow-grid figure {
    margin: 0;
  }

  #ts-meta-note {
    margin-top: 1rem;
    color: #666;
    font-size: 0.875rem;
  }

  #ts-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.72);
    z-index: 9999;
    padding: 16px;
  }

  #ts-modal.is-open {
    display: flex;
  }

  #ts-modal > div {
    position: relative;
    width: min(1000px, 100%);
    background: #fff;
    overflow: hidden;
  }

  #ts-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.55rem 0.95rem;
    border: 1px solid #e6e6e6;
    background: #fff;
    color: var(--prod-blue);
    cursor: pointer;
  }

  #ts-modal-body {
    padding: 1.25rem;
  }

  #ts-modal[data-mode="video"] #ts-modal-close {
    display: none;
  }

  .ts-modal-video-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.5rem;
    border-bottom: 1px solid #e6e6e6;
  }

  .ts-modal-video-title {
    margin: 0;
    color: var(--prod-blue);
    font-weight: 700;
  }

  .ts-modal-inline-close {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 0.95rem;
    border: 1px solid #e6e6e6;
    background: #fff;
    color: var(--prod-blue);
    cursor: pointer;
  }

  .ts-video-wrap {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    background: #000;
  }

  .ts-video-wrap iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
  }

  @media (max-width: 1100px) {
    #ts-series-grid.product-grid,
    #ts-benefits-grid.product-grid,
    #ts-performance-grid.product-grid,
    #ts-protocol-grid.product-grid,
    #ts-workflow-grid {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    #ts-prosthetic-grid.product-grid {
      grid-auto-columns: calc((100% - 2rem) / 2);
    }
  }

  @media (max-width: 900px) {
    .ts-clinical-solutions__layout {
      grid-template-columns: minmax(0, 1fr);
      gap: 2rem;
    }

    .ts-clinical-solutions__content {
      padding-top: 0;
    }
  }

  @media (max-width: 767px) {
    .ts-main {
      padding-bottom: 2.5rem;
    }

    .ts-section,
    .ts-page-hero {
      padding-inline: var(--page-gutter, 16px);
    }

    .ts-page-hero {
      padding-top: 2rem;
      padding-bottom: 2.5rem;
    }

    .ts-page-hero-grid,
    .ts-overview-layout,
    .ts-grid {
      grid-template-columns: minmax(0, 1fr);
      gap: 16px;
    }

    .ts-clinical-solutions__item {
      grid-template-columns: minmax(0, 1fr);
    }

    .ts-lead {
      font-size: var(--fs-body);
      line-height: var(--lh-body);
    }

    .ts-card {
      padding: 1rem;
    }

    #ts-hero-note {
      display: none;
    }

    #ts-hero .banner-image img {
      width: 100%;
      max-width: none;
      object-fit: contain;
    }

    #ts-series-grid.product-grid,
    #ts-benefits-grid.product-grid,
    #ts-performance-grid.product-grid,
    #ts-cases-grid.product-grid,
    #ts-prosthetic-grid.product-grid,
    #ts-detail-grid.product-grid,
    #ts-tools-grid.product-grid,
    #ts-protocol-grid.product-grid,
    #ts-clinical-grid.product-grid,
    #ts-workflow-grid {
      grid-template-columns: 1fr;
    }

    #ts-prosthetic-grid.product-grid {
      grid-template-columns: none;
      grid-auto-columns: min(82vw, 320px);
    }

    .ts-slider-controls {
      display: none;
    }

    #ts-benefits-grid .ts-deep-link-card .card-info,
    #ts-performance-grid .ts-deep-link-card .card-info {
      display: flex;
      align-items: flex-start;
      gap: 0;
    }
  }
}

/* Pagine interne Tapered Series: base condivisa non annidata. */
.page-tapered .ts-main {
  width: min(100% - (var(--page-gutter, 20px) * 2), var(--container, 1480px));
  margin: 0 auto;
  padding: clamp(2rem, 5vw, 5rem) 0 clamp(4rem, 8vw, 7rem);
}

.page-tapered .ts-section {
  margin-top: clamp(2.5rem, 6vw, 5.5rem);
}

.page-tapered .ts-page-hero {
  margin-top: 0;
  padding-bottom: clamp(2.5rem, 5vw, 4.5rem);
  border-bottom: 1px solid #dfe6f2;
}

.page-tapered .ts-page-hero-grid,
.page-tapered .ts-overview-layout,
.page-tapered .ts-grid {
  display: grid;
  gap: clamp(1.25rem, 3vw, 2.5rem);
}

.page-tapered .ts-page-hero-grid {
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  align-items: center;
  margin-top: 2rem;
}

.page-tapered .ts-page-hero-media {
  display: grid;
  min-height: 320px;
  place-items: center;
  background: transparent;
}

.page-tapered .ts-page-hero-media .ts-img {
  width: 100%;
  height: 100%;
  max-height: 440px;
  object-fit: contain;
}

.page-tapered .ts-entry-badge,
.page-tapered .ts-kicker {
  display: block;
  margin: 0 0 0.8rem;
  color: var(--page-accent, #ff0000);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.page-tapered .ts-entry-badge {
  width: fit-content;
  padding: 0.35rem 0.6rem;
  border: 1px solid currentColor;
}

.page-tapered .ts-title {
  max-width: 15ch;
  margin: 0;
  color: #121212;
}

.page-tapered .ts-title-wide,
.page-tapered .ts-title-compact {
  max-width: 22ch;
}

.page-tapered .ts-lead {
  max-width: 62ch;
  margin: 1.5rem 0 0;
  color: #4d5563;
  font-size: clamp(1rem, 1.5vw, 1.18rem);
  line-height: 1.65;
}

.page-tapered .ts-overview-layout {
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  align-items: stretch;
}

.page-tapered .ts-overview-layout-kit {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.page-tapered .ts-overview-stack {
  display: grid;
  gap: 1rem;
}

.page-tapered .ts-card {
  min-width: 0;
  padding: clamp(1.25rem, 3vw, 2rem);
  border: 1px solid #dfe6f2;
  background: #fff;
  box-shadow: none;
}

.page-tapered .ts-overview-stack .ts-card {
  padding-inline: 0;
  border: 0;
  border-top: 1px solid #dfe6f2;
}

.page-tapered .ts-overview-stack .ts-card:last-child {
  border-bottom: 1px solid #dfe6f2;
}

.page-tapered .ts-overview-card-full {
  grid-column: 1 / -1;
}

.page-tapered .ts-overview-card-media,
.page-tapered .ts-overview-card-image-panel {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1.5rem;
}

.page-tapered .ts-subtitle {
  margin: 0 0 0.75rem;
  color: #121212;
  font-size: clamp(1.2rem, 2vw, 1.55rem);
  line-height: 1.2;
}

.page-tapered .ts-card p {
  margin: 0;
  color: #4d5563;
  line-height: 1.65;
}

.page-tapered .ts-img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

.page-tapered .ts-overview-card-media .ts-img,
.page-tapered .ts-overview-card-image-panel .ts-img {
  max-height: 300px;
  margin-top: auto;
}

.page-tapered .ts-data-card-header {
  margin-bottom: 1.5rem;
}

.page-tapered .ts-grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.page-tapered .ts-grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.page-tapered .ts-protocol-card,
.page-tapered .ts-protocol-tool-item {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.page-tapered .ts-protocol-card h4,
.page-tapered .ts-protocol-tool-item h4 {
  margin: 0;
  color: #121212;
  font-size: 1.05rem;
  line-height: 1.35;
}

.page-tapered .ts-protocol-card .ts-img,
.page-tapered .ts-protocol-tool-image {
  max-height: 220px;
  margin-top: auto;
}

.page-tapered .ts-link {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 0.45rem;
  color: var(--page-accent, #ff0000);
  font-weight: 700;
  text-decoration: none;
}

.page-tapered .ts-link:hover,
.page-tapered .ts-link:focus-visible {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.page-tapered .ts-list {
  margin: 0;
  padding-left: 1.25rem;
  color: #4d5563;
  line-height: 1.65;
}

.page-tapered .ts-list li + li {
  margin-top: 0.5rem;
}

.page-tapered .ts-kit-strengths-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.page-tapered .ts-kit-strength-item {
  padding: 1rem 0 0;
  border-top: 2px solid var(--page-accent, #ff0000);
}

.page-tapered .ts-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(0, 0, 0, 0.72);
}

.page-tapered .ts-modal.is-open {
  display: flex;
}

.page-tapered .ts-modal-content {
  position: relative;
  width: min(1000px, 100%);
  max-height: 90vh;
  overflow: auto;
  background: #fff;
}

.page-tapered .ts-modal-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 0.9rem;
  border: 1px solid #d8dde6;
  background: #fff;
  color: var(--page-accent, #ff0000);
  cursor: pointer;
}

.page-tapered .ts-modal-body {
  padding: 1.5rem;
}

@media (max-width: 900px) {
  .page-tapered .ts-page-hero-grid,
  .page-tapered .ts-overview-layout,
  .page-tapered .ts-overview-layout-kit,
  .page-tapered .ts-grid-3,
  .page-tapered .ts-kit-strengths-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .page-tapered .ts-page-hero-copy,
  .page-tapered .ts-page-hero-media,
  .page-tapered .ts-overview-stack,
  .page-tapered .ts-overview-card-media {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .page-tapered .ts-main {
    width: min(100% - 2rem, 1180px);
    padding-top: 2rem;
  }

  .page-tapered .ts-page-hero-grid,
  .page-tapered .ts-overview-layout,
  .page-tapered .ts-overview-layout-kit,
  .page-tapered .ts-grid-2,
  .page-tapered .ts-grid-3,
  .page-tapered .ts-kit-strengths-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .page-tapered .ts-page-hero-media {
    min-height: 240px;
  }

}

/* Slider dei casi clinici nella pagina panoramica. */
.page-tapered #ts-cases-grid.product-grid {
  grid-template-columns: none;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 4rem) / 3);
  overflow-x: auto;
  overflow-y: hidden;
  padding-block: 1rem;
  margin-block: -1rem;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  overscroll-behavior-inline: contain;
}

.page-tapered #ts-cases-grid.product-grid::-webkit-scrollbar { display: none; }

.page-tapered #ts-cases-grid .product-card {
  min-width: 0;
  height: 100%;
  scroll-snap-align: start;
}

.page-tapered .ts-cases-slider { overflow: visible; }

.page-tapered .ts-prosthetic-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
}

.page-tapered .ts-slider-controls {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.page-tapered .ts-slider-button {
  width: 44px;
  height: 44px;
  border: 1px solid #e6e6e6;
  border-radius: 50%;
  background: #fff;
  color: var(--page-accent, #ff0000);
  font-size: 1.25rem;
  cursor: pointer;
}

.page-tapered .ts-slider-button:hover,
.page-tapered .ts-slider-button:focus-visible {
  border-color: var(--page-accent, #ff0000);
  background: var(--page-accent, #ff0000);
  color: #fff;
}

@media (max-width: 1100px) {
  .page-tapered #ts-cases-grid.product-grid { grid-auto-columns: calc((100% - 2rem) / 2); }
}

@media (max-width: 640px) {
  .page-tapered #ts-cases-grid.product-grid { grid-auto-columns: min(82vw, 320px); }
  .page-tapered .ts-prosthetic-heading { align-items: flex-start; }
  .page-tapered .ts-slider-controls { display: flex; margin-bottom: 1rem; }
}

/* Narrow 2.9: pagina focus con struttura condivisa alle pagine prodotto Ortodonzia. */
body[data-product="narrow-2_9"] .narrow-focus-hero .container {
  grid-template-columns: minmax(0, 0.95fr) minmax(420px, 1.05fr);
  gap: clamp(2rem, 5vw, 5rem);
  min-height: 520px;
  padding-top: calc(var(--header-height, 64px) + 3rem);
  padding-bottom: 3rem;
}

body[data-product="narrow-2_9"] .narrow-focus-back {
  margin-bottom: clamp(2rem, 4vw, 4rem);
}

body[data-product="narrow-2_9"] .narrow-focus-kicker {
  margin: 0 0 0.85rem;
  color: var(--page-accent, #ff0000);
  font-size: var(--fs-small);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

body[data-product="narrow-2_9"] .narrow-focus-hero .marpe-hero-header h1 {
  max-width: 9ch;
  color: var(--page-accent, #ff0000) !important;
}

body[data-product="narrow-2_9"] :is(h1, h2, h3, h4, p, a, button) {
  font-family: var(--font-primary);
}

body[data-product="narrow-2_9"] .narrow-focus-hero .marpe-hero-visual {
  min-height: 460px;
}

body[data-product="narrow-2_9"] .narrow-focus-hero .marpe-hero-visual img {
  object-fit: contain;
  object-position: center;
  transform: scale(1.15);
}

body[data-product="narrow-2_9"] .narrow-focus-features {
  padding-top: clamp(3rem, 6vw, 6rem);
}

body[data-product="narrow-2_9"] .narrow-focus-features .feature-card--text-only {
  border-top-color: var(--page-accent, #ff0000);
}

body[data-product="narrow-2_9"] .narrow-focus-editorial .longform-media {
  background: #fafafa;
}

body[data-product="narrow-2_9"] .narrow-focus-editorial .longform-media img {
  object-fit: contain;
  padding: clamp(1.25rem, 3vw, 3rem);
}

body[data-product="narrow-2_9"] .narrow-focus-details {
  background: #f5f7fb;
}

body[data-product="narrow-2_9"] .narrow-focus-table {
  display: grid;
  padding: clamp(1.25rem, 3vw, 3rem);
  place-items: center;
  background: #fff;
  box-shadow: 0 12px 30px rgba(24, 47, 95, 0.08);
}

body[data-product="narrow-2_9"] .narrow-focus-table img {
  width: 100%;
  max-width: 980px;
  height: auto;
}

body[data-product="narrow-2_9"] .narrow-focus-protocol {
  background: #fff;
}

body[data-product="narrow-2_9"] .narrow-focus-protocol .focus-details-header > p {
  margin: 1rem 0 0;
  color: #4d5563;
  line-height: 1.7;
}

body[data-product="narrow-2_9"] .focus-detail-card img {
  display: block;
  width: 100%;
  height: 150px;
  margin-top: 1.5rem;
  object-fit: contain;
}

body[data-product="narrow-2_9"] .focus-detail-card .ts-link {
  margin-top: 1.5rem;
}

@media (max-width: 900px) {
  body[data-product="narrow-2_9"] .narrow-focus-hero .container {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
    padding-top: calc(var(--header-height, 64px) + 2rem);
  }

  body[data-product="narrow-2_9"] .narrow-focus-hero .marpe-hero-visual {
    min-height: 360px;
  }
}

@media (max-width: 640px) {
  body[data-product="narrow-2_9"] .narrow-focus-hero .container {
    padding-top: 2rem;
    padding-bottom: 2rem;
  }

  body[data-product="narrow-2_9"] .narrow-focus-back {
    margin-bottom: 2rem;
  }

  body[data-product="narrow-2_9"] .narrow-focus-hero .marpe-hero-visual {
    min-height: 300px;
  }
}

/* Regole condivise alle pagine focus Narrow. */
body.narrow-focus-page .narrow-focus-hero .container {
  grid-template-columns: minmax(0, 0.95fr) minmax(420px, 1.05fr);
  gap: clamp(2rem, 5vw, 5rem);
  min-height: 520px;
  padding-top: calc(var(--header-height, 64px) + 3rem);
  padding-bottom: 3rem;
}

body.narrow-focus-page .narrow-focus-back { margin-bottom: clamp(2rem, 4vw, 4rem); }

body.narrow-focus-page .narrow-focus-hero .marpe-hero-header h1 {
  max-width: 9ch;
  color: var(--page-accent, #ff0000) !important;
}

body.narrow-focus-page :is(h1, h2, h3, h4, p, a, button) { font-family: var(--font-primary); }

body.narrow-focus-page .narrow-focus-hero .marpe-hero-visual { min-height: 460px; }
body.narrow-focus-page .narrow-focus-hero .marpe-hero-visual img { object-fit: contain; object-position: center; transform: scale(1.15); }
body.narrow-focus-page .narrow-focus-features { padding-top: clamp(3rem, 6vw, 6rem); }
body.narrow-focus-page .narrow-focus-features .feature-card--text-only { border-top-color: var(--page-accent, #ff0000); }
body.narrow-focus-page .narrow-focus-editorial .longform-media { background: transparent; }
body.narrow-focus-page .narrow-focus-editorial > .container {
  grid-template-columns: minmax(340px, 0.95fr) minmax(0, 1.05fr);
}
body.narrow-focus-page .narrow-focus-editorial .longform-media img { object-fit: contain; padding: clamp(0.5rem, 1vw, 1rem); }
body.narrow-focus-page .narrow-focus-editorial img[data-modal-image] { cursor: zoom-in; }
body.narrow-focus-page .narrow-focus-details { background: #f5f7fb; }
body.narrow-focus-page .narrow-focus-table { display: grid; padding: clamp(1.25rem, 3vw, 3rem); place-items: center; background: #fff; box-shadow: 0 12px 30px rgba(24, 47, 95, 0.08); }
body.narrow-focus-page .narrow-focus-table img { width: 100%; max-width: 980px; height: auto; }
body.narrow-focus-page .narrow-focus-protocol { background: #fff; }
body.narrow-focus-page .narrow-focus-protocol .focus-details-header > p { margin: 1rem 0 0; color: #4d5563; line-height: 1.7; }
body.narrow-focus-page .focus-detail-card img { display: block; width: 100%; height: 150px; margin-top: 1.5rem; object-fit: contain; }
body.narrow-focus-page .focus-detail-card img[data-modal-image] { cursor: zoom-in; }
body.narrow-focus-page .focus-detail-card .ts-link { margin-top: 1.5rem; }
body.narrow-focus-page .focus-detail-card ul { margin: 0; padding-left: 1.15rem; color: #4d5563; }
body.narrow-focus-page .focus-detail-card li + li { margin-top: 0.65rem; }

/* Monconi protesici: le immagini di gamma mantengono le proporzioni originali. */
body.prosthetic-focus-page .narrow-focus-hero .marpe-hero-visual img {
  transform: none;
}

body.prosthetic-focus-page .narrow-focus-editorial:not(.section-longform--with-media) > .container {
  grid-template-columns: minmax(280px, 0.75fr) minmax(0, 1.25fr);
  align-items: start;
}

/* Cono Morse autobloccante: immagini tecniche e griglie dedicate. */
body[data-product="locking-morse"] .morse-hero {
  display: flex;
  align-items: center;
}

body[data-product="locking-morse"] .morse-hero .container {
  display: flex;
  position: relative;
  align-items: center !important;
  min-height: 0;
  padding-top: 0;
  padding-bottom: 0;
}

body[data-product="locking-morse"] .morse-hero .marpe-hero-content {
  z-index: 10;
  width: 50%;
  max-width: 50%;
  margin: 0;
  padding: 2rem;
}

body[data-product="locking-morse"] .morse-hero .marpe-hero-header {
  margin: 0;
}

body[data-product="locking-morse"] .morse-hero .marpe-hero-header h1 {
  display: block;
  max-width: none;
  margin: 0;
}

body[data-product="locking-morse"] .morse-hero .marpe-hero-visual {
  position: absolute;
  top: 0;
  right: -5vw;
  width: 70vw;
  height: 100%;
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

body[data-product="locking-morse"] .morse-hero .marpe-hero-visual img {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: contain;
  object-position: right center;
  transform: scale(1.18);
  transform-origin: right center;
}

body[data-product="locking-morse"] .morse-editorial .longform-media {
  min-height: 420px;
  background: transparent;
}

body[data-product="locking-morse"] .morse-editorial .longform-media img {
  width: 100%;
  height: 100%;
  max-height: 520px;
  object-fit: contain;
}

body[data-product="locking-morse"] .morse-connection-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

body[data-product="locking-morse"] .morse-connection-card img {
  width: 100%;
  height: 260px;
  margin-top: 1.25rem;
  object-fit: contain;
}

body[data-product="locking-morse"] .morse-connection-card .focus-detail-card__body {
  display: flex;
  flex-direction: column;
  height: 100%;
}

body[data-page="tapered-series"] #ts-cases-prev,
body[data-page="tapered-series"] #ts-cases-next {
  border-radius: 0;
}

@media (max-width: 900px) {
  body.narrow-focus-page .narrow-focus-hero .container { grid-template-columns: minmax(0, 1fr); min-height: 0; padding-top: calc(var(--header-height, 64px) + 2rem); }
  body.narrow-focus-page .narrow-focus-editorial > .container { grid-template-columns: minmax(0, 1fr); }
  body.narrow-focus-page .narrow-focus-hero .marpe-hero-visual { min-height: 360px; }
  body[data-product="locking-morse"] .morse-hero .container {
    display: flex !important;
    flex-direction: column;
    gap: 0 !important;
    padding: 0;
  }
  body[data-product="locking-morse"] .morse-hero .marpe-hero-visual {
    position: relative !important;
    order: -1;
    right: auto;
    width: 100% !important;
    height: 50vh !important;
    min-height: 300px !important;
    border: 0 !important;
    background: transparent !important;
  }
  body[data-product="locking-morse"] .morse-hero .marpe-hero-visual img {
    max-height: none !important;
    min-height: 0 !important;
    transform: none;
  }
  body[data-product="locking-morse"] .morse-hero .marpe-hero-content {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 2rem 1rem;
    text-align: center;
  }
  body[data-product="locking-morse"] .morse-connection-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 640px) {
  body.narrow-focus-page .narrow-focus-hero .container { padding-top: 2rem; padding-bottom: 2rem; }
  body.narrow-focus-page .narrow-focus-back { margin-bottom: 2rem; }
  body.narrow-focus-page .narrow-focus-hero .marpe-hero-visual { min-height: 300px; }
  body[data-product="locking-morse"] .morse-hero .container { padding: 0; }
  body[data-product="locking-morse"] .morse-hero .marpe-hero-header h1 { max-width: none; }
  body[data-product="locking-morse"] .morse-editorial .longform-media { min-height: 300px; }
  body[data-product="locking-morse"] .morse-connection-card img { height: 190px; }
}

/* Image dialogs scroll internally; the close control stays outside the scroll area. */
#ts-modal[data-mode="image"] > .ts-modal-content {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  max-height: calc(100dvh - 2rem);
  overflow: hidden;
}
#ts-modal[data-mode="image"] #ts-modal-close {
  position: relative;
  inset: auto;
  justify-self: end;
  margin: 0.75rem 0.75rem 0;
}
#ts-modal[data-mode="image"] #ts-modal-body {
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
#ts-modal[data-mode="image"] #ts-modal-body img {
  display: block;
  width: 100%;
  height: auto;
  max-height: none;
}
#ts-modal[data-mode="image"] #ts-modal-body:focus-visible {
  outline: 2px solid var(--page-accent, #ff0000);
  outline-offset: -3px;
}
