/* iPhone category: compact Apple-inspired model navigation + direct catalog.
   Scope intentionally limited to /iphone/; no global shop/checkout changes. */
.iphone-category-page .page-hero { padding: 23px 0 9px; }
.iphone-category-page .page-hero__grid { display: block; }
.iphone-category-page .page-hero h1 { max-width: none; font-size: clamp(2.3rem, 7vw, 3.7rem); letter-spacing: -.055em; line-height: 1.05; margin: 0 0 8px; }
.iphone-category-page .page-hero__lede { font-size: clamp(.85rem, 2vw, .98rem); line-height: 1.5; max-width: 68ch; }
.iphone-category-page .page-hero__aside,
.iphone-category-page .page-hero .button-row,
.iphone-category-page .page-hero .eyebrow { display: none; }
.iphone-category-page .breadcrumbs { margin-bottom: 12px; }
.iphone-model-nav { background: #fff; border-bottom: 1px solid #e5e5e7; }
.iphone-model-nav__inner { position: relative; }
.iphone-model-nav__rail { display: flex; gap: 4px; overflow-x: auto; overscroll-behavior-inline: contain; padding: 18px 36px 8px; scroll-snap-type: x proximity; scroll-padding-inline: 36px; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.iphone-model-nav__rail::-webkit-scrollbar { display: none; }
.iphone-model-nav__item { flex: 0 0 124px; width: 124px; scroll-snap-align: start; display: grid; grid-template-rows: 96px auto; align-items: end; justify-items: center; gap: 8px; padding: 6px 8px 14px; border-radius: 16px; text-align: center; color: #1d1d1f; text-decoration: none; }
.iphone-model-nav__item:hover, .iphone-model-nav__item[aria-current="true"] { background: #f5f5f7; }
.iphone-model-nav__item:focus-visible { outline: 2px solid #0071e3; outline-offset: -2px; }
.iphone-model-nav__image { width: 100%; height: 96px; display: flex; align-items: flex-end; justify-content: center; overflow: hidden; }
.iphone-model-nav__image img { display: block; width: 100%; height: 100%; object-fit: contain; object-position: center bottom; }
.iphone-model-nav__image--empty::before { content: ""; width: calc(var(--iphone-mm, 147) / 163.4 * 42px); height: calc(var(--iphone-mm, 147) / 163.4 * 92px); margin-bottom: 2px; border: 1.5px solid #d2d2d7; border-radius: 9px; background: linear-gradient(#fff, #fff) center 9px / 16px 3px no-repeat, #f5f5f7; box-shadow: inset 0 -14px 0 #fff; }
.iphone-category-page .product-card__media { place-items: end center; padding: 14px 12px 10px; }
.iphone-category-page .product-card__media img { object-position: center bottom; }
.iphone-model-nav__copy { align-self: start; display: grid; align-content: start; gap: 2px; width: 100%; min-height: 2.6em; }
.iphone-model-nav__name { display: block; max-height: 3.75em; overflow: hidden; font-size: 12px; line-height: 1.25; font-weight: 600; letter-spacing: -0.01em; }
.iphone-model-nav__new { color: #bf4800; font-size: 12px; font-weight: 600; line-height: 1.1; }
.iphone-model-nav__item[aria-current="true"] .iphone-model-nav__name { color: #0066cc; }
.iphone-model-nav__chevron { position: absolute; top: 52px; z-index: 2; width: 36px; height: 36px; border: 0; border-radius: 50%; background: #fff; box-shadow: 0 2px 8px rgb(0 0 0 / 16%); cursor: pointer; }
.iphone-model-nav__chevron::before { content: ""; display: block; width: 8px; height: 8px; margin: 0 auto; border-right: 2px solid #1d1d1f; border-bottom: 2px solid #1d1d1f; }
.iphone-model-nav__chevron--prev { left: 4px; }
.iphone-model-nav__chevron--prev::before { transform: rotate(135deg); margin-left: 12px; }
.iphone-model-nav__chevron--next { right: 4px; }
.iphone-model-nav__chevron--next::before { transform: rotate(-45deg); margin-right: 12px; }
.iphone-model-nav__chevron[hidden] { display: none; }
.iphone-category-page .seo-collection { padding: 21px 0 58px; }
.iphone-catalog-controls { display: grid; gap: 4px; }
.iphone-catalog-controls__top { display: flex; justify-content: space-between; align-items: end; gap: 10px; }
.iphone-catalog-controls__top h2 { font-size: clamp(1.7rem, 4vw, 2.4rem); letter-spacing: -.04em; margin: 0; }
.iphone-catalog-controls__count { margin: 0; font-size: .82rem; color: #6e6e73; white-space: nowrap; }
.iphone-category-page .seo-collection .product-grid { margin-top: 14px; }
.iphone-category-page .seo-collection .product-card[hidden] { display: none !important; }
.iphone-catalog-empty { padding: 32px 0; text-align: center; color: #6e6e73; }
.iphone-catalog-empty[hidden] { display: none; }
@media (max-width: 560px) {
 .iphone-category-page .page-hero { padding: 15px 0 6px; }
 .iphone-category-page .page-hero__lede { font-size: 12px; }
 .iphone-category-page .breadcrumbs { display: none; }
 .iphone-model-nav__rail { gap: 0; padding: 12px 8px 4px; scroll-padding-inline: 8px; }
 .iphone-model-nav__item { flex-basis: 112px; width: 112px; grid-template-rows: 88px auto; padding: 4px 6px 12px; }
 .iphone-model-nav__image { height: 88px; }
 .iphone-model-nav__chevron { display: none; }
 .iphone-category-page .seo-collection { padding: 18px 0 44px; }
}
@media (prefers-reduced-motion: reduce) {
 .iphone-model-nav__item { transition: none; }
}


/* Direct category filtering — clear controls, small tap-safe mobile layout. */
.iphone-catalog-controls { gap: 12px; scroll-margin-top: 114px; }
.iphone-catalog-controls__filters select:focus-visible,
.iphone-catalog-controls__clear:focus-visible {
  outline: 2px solid #0071e3;
  outline-offset: 2px;
}
.iphone-catalog-controls__filters {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 10px;
}
.iphone-catalog-controls__select-label {
  display: grid;
  flex: 1 1 195px;
  gap: 5px;
  min-width: 0;
  color: #6e6e73;
  font-size: 12px;
  font-weight: 600;
}
.iphone-catalog-controls__filters select {
  width: 100%;
  min-width: 0;
  height: 44px;
  padding: 0 13px;
  border: 1px solid #d2d2d7;
  border-radius: 12px;
  background: #fff;
  color: #1d1d1f;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
}
.iphone-catalog-controls__verified {
  align-items: center;
  gap: 7px;
  min-height: 44px;
  font-size: 13px;
  font-weight: 500;
  color: #1d1d1f;
}
.iphone-catalog-controls__verified:not([hidden]) { display: inline-flex; }
.iphone-catalog-controls__verified input { width: 18px; height: 18px; accent-color: #0066cc; }
.iphone-catalog-controls__clear {
  min-height: 44px;
  padding: 0 10px;
  border: none;
  background: transparent;
  color: #0066cc;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.iphone-catalog-controls__clear:hover { text-decoration: underline; }
.iphone-catalog-controls__clear[hidden],
.iphone-catalog-controls__verified[hidden] { display: none !important; }
@media (max-width: 560px) {
  .iphone-catalog-controls__filters { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 8px; }
  .iphone-catalog-controls__select-label { min-width: 0; }
  .iphone-catalog-controls__filters select { font-size: 13px; padding-inline: 8px; }
  .iphone-model-nav__item {
    flex: 0 0 89px;
    width: 89px;
    grid-template-rows: 70px auto;
    gap: 4px;
    padding: 4px 3px 8px;
    border-radius: 12px;
  }
  .iphone-model-nav__image { height: 70px; }
  .iphone-model-nav__image--empty::before { height: calc(var(--iphone-mm, 147) / 163.4 * 67px); width: calc(var(--iphone-mm, 147) / 163.4 * 35px); }
  .iphone-model-nav__copy { min-height: 2.55em; gap: 3px; }
  .iphone-model-nav__name { font-size: 10.5px; }
  .iphone-model-nav__new { font-size: 10px; }
  .iphone-catalog-controls__top h2 { font-size: clamp(1.55rem, 6vw, 1.95rem); }
  .iphone-catalog-controls__count { font-size: 12px; }
}
@media (max-width: 349px) {
  .iphone-model-nav__item { flex-basis: 82px; width: 82px; }
  .iphone-catalog-controls__filters select { font-size: 12px; }
}
