@media all and (max-width: 768px) {
  .page-tower-product-detail {
    margin-top: 0;
  }
}

.page-tower-product-detail {
  padding-top: var(--site-header-offset, 80px);
  overflow-x: auto;
  /* Changed from hidden to allow horizontal scroll on PC */
}

/* Tabs */
.product-tabs {
  max-width: 120rem;
  margin: 4rem auto 0;
  padding: 0 4rem;
  display: flex;
  gap: 1.1rem;
  position: relative;
  z-index: 10;
}

.product-tabs__item {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 2rem;
  font-size: 1.6rem;
  font-weight: 700;
  color: #4a545d;
  background: #fff;
  text-decoration: none;
  border: 1px solid #bebebe;
  border-radius: 0.4rem;
  transition: all 0.3s;
  position: relative;
}

.product-tabs__item--left {
  width: calc(48.5% - 0.5rem);
  padding-left: 3.6rem;
}

.product-tabs__item--right {
  width: calc(51.5% - 0.6rem);
}

.product-tabs__item img {
  position: absolute;
  right: 1.9rem;
  top: 55%;
  transform: translateY(-50%);
}

/* Main Content Layout */
.product-detail-main {
  max-width: 120rem;
  margin: 7.3rem auto 0;
  padding: 0 4rem;
  display: flex;
  gap: 2.8rem;
}

/* Force horizontal scroll on PC for the entire page (Header, Hero, Footer included) when width is small (<= 1121px) */
@media screen and (min-width: 769px) {
  .page-tower-product-detail #container {
    min-width: 1120px;
  }
}

/* Main Content Area */
.product-detail-main__content {
  flex: 1;
  min-width: 0;
}

.product-features__inner {
  display: flex;
  gap: 2.7rem;
  align-items: flex-start;
}

.product-features__image-area {
  flex: 0 0 48%;
}

.product-features__main-image {
  width: 100%;
  height: auto;
  display: block;
}

.product-features__info-area {
  flex: 1;
  padding-right: 4.5rem;
}

.product-features__list {
  list-style: none;
  padding: 0;
  margin-top: 2.6rem;
  font-size: 2rem;
  font-weight: 500;
  color: #4a545d;
}

.product-features__list li {
  font-family: 'Noto Sans JP', sans-serif;
  font-style: normal;
  font-weight: 500;
  color: #4a545d;
  margin-bottom: 0.5rem;
  line-height: 2.8rem;
}

.product-features__desc {
  font-size: 1.6rem;
  line-height: 1.5;
  color: #4a545d;
  margin-bottom: 2rem;
  font-weight: 400;
}

/* Specs Link */
.product-features__specs-title {
  font-size: 1.6rem;
  font-weight: 500;
  color: #4a545d;
  margin: 0 0 1.1rem;
}

.product-features__specs-thumb {
  border: 1px solid #eee;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s;
}

.product-features__specs-thumb img:hover {
  transform: translateY(-2px);
}

.quote-form__select.is-turbo-freezing {
  line-height: 1.1;
  padding-top: 0;
  padding-bottom: 2px;
}

/* ===== SECTION HEADING ===== */
.section-heading {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 3.6rem;
  margin-left: 1rem;
}

.section-heading::before {
  content: '';
  width: 0.6rem;
  height: 2.4rem;
  background: #eb3b3b;
  border-radius: 0.2rem;
  flex-shrink: 0;
}

.section-heading__title {
  font-size: 2rem;
  font-weight: 500;
  color: #eb3b3b;
  display: block;
}

/* ===== STRUCTURE DIAGRAM ===== */
.structure-diagram {
  margin-top: 6.6rem;
  padding: 0 3.8rem;
}

.structure-diagram__content {
  text-align: center;
}

.structure-diagram__image {
  max-width: 100%;
  height: auto;
}

/* ===== OTHER PRODUCTS ===== */
.other-products {
  margin-top: 12rem;
  margin-bottom: 9.8rem;
  padding-left: 2.8rem;
}

/* round-type only: align page-end scroll depth with index layout */
.page-tower-product-round-type .other-products {
  margin-bottom: 4rem;
}

.page-tower-product-round-type .product-card {
  border: none;
}

.other-products__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2.3rem;
  margin-top: 4.2rem;
  align-items: stretch;
}

/* ===== PRODUCT CARD ===== */
.product-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  text-decoration: none;
}

/* Image area */
.product-card__image-wrap {
  position: relative;
  background: #fff;
  overflow: hidden;
  aspect-ratio: 350/254;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-card__image {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Content area */
.product-card__content {
  padding: 1.3rem 0.3rem 0;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  margin-bottom: 0.5rem;
}

.product-card__title {
  font-size: 2rem;
  font-weight: 500;
  color: #4a545d;
}

/* Description */
.product-card__desc {
  font-size: 1.6rem;
  line-height: 1.5;
  color: #4a545d;
  margin-bottom: 1rem;
  margin-left: 0.3rem;
  flex: 1;
}

/* Catalog button */
.product-card__button {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  justify-content: center;
  padding: 0.7rem 2.5rem;
  font-size: 1.4rem;
  font-weight: 400;
  color: #fff;
  background: #8b959e;
  border-radius: 0.5rem;
  width: fit-content;
  margin-top: auto;
  margin-left: 0.3rem;
}

/* PDF icon */
.product-card__button-icon {
  width: 1.3rem;
  height: 1.5rem;
  background: url('../../img/tower/icon-metro-file-pdf.webp') no-repeat center;
  background-size: contain;
}

/* Red circle arrow */
.product-card__arrow {
  display: block;
  width: 2.3rem;
  height: 2.3rem;
  background: #eb3b3b url('../../img/tower/icon-feather-arrow-right.svg') no-repeat center;
  background-size: 1rem 1rem;
  border-radius: 50%;
  flex-shrink: 0;
  margin-left: 5px;
  margin-right: 0;
}

/* ====Useful Info === */
.useful-info {
  margin-top: 5.4rem;
  padding-left: 4rem;
}

/* === Banner === */
.useful-info__banner {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  background: linear-gradient(90deg,
      #4a3d6a 0.5%,
      rgba(58, 90, 205, 0.62) 45.03%,
      rgba(112, 158, 239, 0.34) 69.47%,
      rgba(97, 169, 246, 0) 99.92%);
  border-radius: 2rem 0 0 2rem;
  overflow: hidden;
  margin-bottom: 2rem;
  width: 100%;
  position: relative;
  /* max-width removed */
}

.useful-info__banner-content {
  flex: 1;
  padding: 2.7rem 2.5rem 2.4rem 2.3rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 3.1rem;
  font-size: 1.6rem;
  font-weight: 400;
  line-height: 1.5;
}

.useful-info__banner-text {
  font-size: 1.6rem;
  line-height: 1.5;
  color: #fff;
  font-weight: 400;
  white-space: nowrap;
}

.useful-info__banner-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  min-height: 7rem;
  padding: 1rem 5.8rem 1rem 6.4rem;
  font-size: 1.4rem;
  font-weight: 500;
  color: #4a545d;
  background: #fff;
  border-radius: 0.6rem;
  text-decoration: none;
  width: fit-content;
  min-width: 20rem;
  transition: background 0.3s ease;
}

.useful-info__banner-link:hover {
  background: #f5f5f5;
}

.useful-info__banner-arrow {
  display: block;
  width: 2.3rem;
  height: 2.3rem;
  background: #eb3b3b url('../../img/tower/icon-feather-arrow-right.svg') no-repeat center;
  background-size: 1rem 1rem;
  border-radius: 50%;
  position: absolute;
  right: 0.5rem;
  bottom: 0.6rem;
}

.useful-info__banner-image {
  flex: 0 0 45%;
  overflow: hidden;
  position: absolute;
  right: 0;
  bottom: 0;
  z-index: -1;
}

.useful-info__banner-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: left center;
  display: block;
}

/* === Banner === */
.useful-info__banner--cards {
  padding: 0 2.5rem;
  margin-right: -4rem;
  flex-wrap: wrap;
  z-index: 1;
}

.useful-info__banner.useful-info__banner--cards::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg,
      #4a3d6a 0%,
      rgba(58, 90, 205, 0.62) 45%,
      rgba(112, 158, 239, 0.34) 69%,
      rgba(97, 169, 246, 0) 100%);
}

.useful-info__banner.useful-info__banner--cards::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(359deg,
      #4a3d6a -19.38%,
      rgba(58, 90, 205, 0.62) 33.7%,
      rgba(112, 158, 239, 0.34) 62.83%,
      rgba(97, 169, 246, 0) 99.12%);
}

.useful-info__banner--cards .useful-info__banner-content {
  padding: 2.7rem 0 2.4rem 0;
  gap: 2rem;
  /* Increased gap for groups */
  width: 100%;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: flex-start;
}

.useful-info__item {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  width: 220px;
}

.useful-info__banner--cards .useful-info__banner-link {
  width: 294px;
  height: 70px;
  padding: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
}

@media screen and (min-width: 769px) {
  .useful-info__banner {
    margin-right: max(min(-4rem, calc(56rem - 50vw)), calc(50% - 87.5rem));
    width: auto;
  }

  .useful-info__banner--cards .useful-info__banner-content {
    display: grid;
    grid-template-columns: repeat(3, 220px);
    justify-content: start;
    gap: 2rem;
  }

  .useful-info__banner--cards .useful-info__banner-text {
    grid-column: 1 / -1;
    width: 100%;
  }

  .useful-info__banner:not(.useful-info__banner--cards) .useful-info__banner-link,
  .useful-info__banner--cards .useful-info__banner-link {
    width: 220px;
    height: 70px;
    min-width: auto;
    min-height: auto;
    padding: 0;
    display: flex;
  }
}

@media screen and (min-width: 769px) and (max-width: 1366px) {
  .page-tower-product-round-type .useful-info__banner--cards .useful-info__banner-content {
    grid-template-columns: repeat(3, 200px);
    gap: 2rem 1.5rem;
  }

  .page-tower-product-round-type .useful-info__banner--cards .useful-info__item,
  .page-tower-product-round-type .useful-info__banner--cards .useful-info__banner-link {
    width: 200px;
  }
}

@media screen and (min-width: 769px) and (max-width: 1121px) {
  .useful-info__banner--cards .useful-info__banner-content {
    grid-template-columns: repeat(3, 200px);
    gap: 2rem 1.5rem;
  }

  .useful-info__banner:not(.useful-info__banner--cards) .useful-info__banner-link,
  .useful-info__banner--cards .useful-info__banner-link {
    width: 200px;
  }
}

.useful-info__banner--cards .useful-info__banner-arrow {
  position: absolute;
  right: 0.5rem;
  bottom: 0.6rem;
  top: auto;
  transform: none;
}

/* Inner content */
.useful-info__link-title {
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: #4a545d;
  line-height: 1.4;
}

.useful-info__link-desc {
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 13px;
  font-weight: 400;
  color: #fff;
  line-height: 1.5;
  margin: 0;
}

.product-background {
  background: #f7f7f7;
  height: 4rem;
  border-radius: 0 4rem 0 0;
}

/* ===== RESPONSIVE ===== */
@media screen and (max-width: 768px) {
  .page-tower-product-detail {
    padding-top: var(--site-header-offset, 73px);
  }

  .product-tabs {
    flex-direction: column;
    gap: 4px;
    align-items: center;
  }

  .product-tabs__item {
    width: 100%;
    max-width: 390px;
    height: 46px;
    padding: 0;
  }

  .product-tabs__item--left,
  .product-tabs__item--right {
    width: 100%;
    max-width: 390px;
  }

  .product-tabs__item--left {
    padding-left: 0;
  }

  .product-detail-main {
    flex-direction: column;
    padding: 0 2.4rem;
  }
  .product-detail-main__sidebar {
    width: 100%;
    margin-top: 4rem;
    margin-bottom: 4rem;
    border-radius: 2rem;
    padding: 0;
    /* Reset padding for SP if needed, previously was 6.5rem... check original */
    background: transparent;
    /* Remove background on wrapper if copying index style */
  }

  /* Resetting the Sidebar container styles for SP to match behavior */
  .product-detail-main__sidebar {
    padding: 0;
    background: transparent;
  }

  .product-detail-main__sidebar::before {
    display: none;
  }

  /* Sidebar Box adaptation for SP */
  .sidebar-box {
    padding: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    position: static;
    /* Remove sticky */
  }

  .sidebar-box__title {
    margin-bottom: 0;
  }


  /* Toggle Button Styles for SP */
  .sidebar-toggle {
    background: #8b959e;
    color: #fff;
    width: 100%;
    margin-left: 0;
    padding: 0 1.6rem;
    min-height: 43px;
    /* Match index.css min-height */
    font-size: 1.6rem;
    justify-content: center;
    gap: 0.8rem;
    /* Match index.css gap */
    cursor: pointer;
    position: relative;
    border-radius: 0;
    /* Match index.css border-radius */
    pointer-events: auto;
  }

  .sidebar-toggle-icon {
    display: block;
    /* No width/height on wrapper, allow before to handle it? 
         Wait, index.css has .sidebarToggleIcon::before but no style on .sidebarToggleIcon itself other than block?
         Let's check index.css again. 
         .sidebarToggleIcon::before { ... } 
         But where is .sidebarToggleIcon sized? It's likely just a wrapper.
      */
  }

  .sidebar-toggle-icon::before {
    content: '';
    display: block;
    width: 0.75rem;
    height: 0.75rem;
    border-top: 0.2rem solid #fff;
    border-right: 0.2rem solid #fff;
    transform: rotate(-45deg);
    /* Default (collapsed, showing down/right logic from index) */
    /* Note: In index.css, default is -45deg. 
         Wait, index.css says:
         .sidebarToggleIcon::before { transform: rotate(-45deg); }
         .sidebarToggle[aria-expanded="true"] .sidebarToggleIcon::before { transform: rotate(135deg); }
      */
    transition: transform 0.3s;
    margin-top: -0.2rem;
    /* Minor adjustment from standard if needed, index doesn't have it but good for alignment */
  }

  /* When expanded (aria-expanded="true"), rotate to 135deg */
  .sidebar-toggle[aria-expanded='true'] .sidebar-toggle-icon::before {
    transform: rotate(135deg);
    margin-top: 0.2rem;
    /* Adjustment for visual center */
  }

  /* The Panel */
  [data-sidebar-panel] {
    background: #fff;
    padding: 2.4rem;
    border-radius: 0 0 1.2rem 1.2rem;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  }

  /* When expanded, the title needs to look connected? 
     Index.css doesn't seem to change border-radius on toggle.
     It keeps border-radius: 0.
     However, my sidebar box has radius.
     Let's keep the box clean.
  */

  /* When expanded, the title needs to look connected? 
     Index.css doesn't seem to change border-radius on toggle.
     It keeps border-radius: 0.
     However, my sidebar box has radius.
     Let's keep the box clean.
  */

  /* Removed conflicting width reset to ensure full-width persistence */

  /* Re-defining toggle to match index visual but fit my layout */
  .sidebar-toggle {
    background: #8b959e;
    color: #fff;
    width: 100%;
    margin-left: 0;
    padding: 0 1.6rem;
    min-height: 43px;
    font-size: 1.6rem;
    justify-content: center;
    gap: 0.8rem;
    cursor: pointer;
    position: relative;
    pointer-events: auto;
    border-radius: 0;
  }

  /* Form spacing inside panel */
  .quote-form {
    gap: 1.6rem;
  }

  .product-features__inner {
    flex-direction: column;
  }

  .product-features__image-area {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
  }

  .product-features__info-area {
    padding-right: 0;
  }

  .other-products__grid {
    display: flex;
    overflow-x: auto;
    gap: 23px;
    margin-right: -24px;
    padding-right: 24px;
    padding-bottom: 1rem;
  }

  .product-card {
    width: 266px;
    min-width: 266px;
    flex-shrink: 0;
  }

  .useful-info__banner {
    flex-direction: column;
    width: 100%;
    /* max-width: 100%; */
  }

  .useful-info__banner-content {
    padding: 24px;
  }

  .useful-info__banner-image {
    flex: 0 0 auto;
    max-width: 100%;
    height: 20rem;
  }

  .useful-info__banner--cards {
    margin-right: 0;
    border-radius: 2rem;
    background-size: cover;
  }

  .useful-info__cards {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding: 1rem 2rem 2rem;
  }

  .useful-info__card {
    border-radius: 1.5rem;
  }

  /* Adjustments for SP Images (Requested: Responsive ratio based on 350px/390px = ~90% or just fill available space) */
  .product-features__specs-link {
    display: block;
    width: 100%;
    margin: 0 auto;
    line-height: 0;
    /* Removing whitespace/gap */
  }

  .product-features__specs-thumb {
    width: 100%;
    margin: 0;
  }

  .product-features__specs-thumb img {
    width: 100%;
    height: auto;
    vertical-align: bottom;
    /* Removes bottom spacing */
  }

  .structure-diagram {
    padding: 0;
  }

  .structure-diagram__content {
    width: 100%;
    margin: 0 auto;
  }

  .structure-diagram__image {
    width: 100%;
    height: auto;
  }

  /* Useful Info Section SP Design */
  .useful-info {
    padding-left: 0;
    padding-right: 0;
  }

  /* First Banner (Technical Info) */
  .useful-info__banner:not(.useful-info__banner--cards) {
    width: 93.33vw;
    height: 228px;
    border-radius: 20px 0 0 20px;
    margin-left: auto;
    margin-right: -24px;
    /* Right aligned */
  }

  .useful-info__banner:not(.useful-info__banner--cards) .useful-info__banner-content,
  .useful-info__banner--cards .useful-info__banner-content {
    position: relative;
    z-index: 1;
  }

  .useful-info__banner:not(.useful-info__banner--cards) .useful-info__banner-content {
    /* padding: 5.13vw;
    padding-left: calc(5.13vw + 25px); */
    width: 100%;
    padding: 5.13vw 2.5rem;
  }

  .useful-info__banner:not(.useful-info__banner--cards) .useful-info__banner-text {
    font-family: 'Noto Sans JP', sans-serif;
    font-size: 16px;
    font-style: normal;
    font-weight: 400;
    line-height: 24px;
    /* 150% */
    color: #fff;
    white-space: normal;
  }

  .useful-info__banner:not(.useful-info__banner--cards) .useful-info__banner-link,
  .useful-info__banner--cards .useful-info__banner-link {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 100%;
    height: 70px;
    background: #fff;
    border-radius: 6px;
    text-decoration: none;
    transition: background 0.3s ease;
    padding: 0;
    /* Reset PC padding */
    min-height: auto;
    min-width: auto;
    box-shadow: none;
    text-align: center;
  }

  .useful-info__banner:not(.useful-info__banner--cards) .useful-info__banner-link span:first-of-type {
    color: #4a545d;
    text-align: center;
    font-family: 'Noto Sans JP', sans-serif;
    font-size: 14px;
    font-style: normal;
    font-weight: 500;
    line-height: 53px;
    /* 378.571% */
    leading-trim: both;
    text-edge: cap;
  }

  /* Second Banner (Cards) */
  .useful-info__banner--cards {
    width: 93.33vw;
    height: 492px;
    border-radius: 20px 0 0 20px;
    margin-left: auto;
    margin-right: -24px;
    /* Right aligned */
  }

  .useful-info__banner--cards .useful-info__banner-text {
    font-family: 'Noto Sans JP', sans-serif;
    font-size: 16px;
    font-style: normal;
    font-weight: 400;
    line-height: 24px;
    /* 150% */
    color: #fff;
    white-space: normal;
  }

  .useful-info__banner:not(.useful-info__banner--cards) .useful-info__banner-image,
  .useful-info__banner--cards .useful-info__banner-image {
    right: 0;
    bottom: 0;
    position: absolute;
    flex: none;
    max-width: none;
  }

  .useful-info__banner--cards .useful-info__banner-content {
    flex-direction: column;
  }

  .useful-info__item {
    width: 100%;
    align-items: flex-start;
  }

  .useful-info__banner--cards .useful-info__banner-image {
    max-width: none;
    width: auto;
    height: auto;
    z-index: 0;
  }

  .useful-info__banner--cards .useful-info__banner-image img {
    width: auto;
    height: auto;
    max-height: 200px;
    object-fit: contain;
    object-position: right bottom;
  }

  .useful-info__item .useful-info__banner-arrow {
    position: absolute;
    right: 0.5rem;
    bottom: 0.6rem;
    top: auto;
    transform: none;
  }

  .section-heading {
    margin-left: 0;
  }

  .other-products {
    padding-left: 0;
  }
}

@media screen and (max-width: 473px) {
  .page-tower-product-round-type .useful-info__banner--cards {
    height: 525px;
  }

  .page-tower-product-round-type .useful-info__banner--cards .useful-info__banner-content {
    box-sizing: border-box;
    padding-bottom: 33px !important;
  }
}
