.material-hero {
  padding-top: 40px;
  padding-bottom: 12px;
}
@media (prefers-reduced-motion: reduce) {
  .material-photo,
  .material-photo img {
    transition: none;
    transform: none;
  }
}
.material-crumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
  color: var(--muted);
  font-size: 13px;
}
.material-crumb a:hover {
  color: var(--brand, #b4231c);
}
.material-hero h1 {
  max-width: 18ch;
}
.material-lead {
  max-width: 62ch;
  margin: 18px 0 26px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.65;
}
.material-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
}
.material-count {
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}
.material-gallery-block {
  padding-block: 32px 24px;
}
.material-filters {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}
.material-filters label {
  color: var(--muted);
  font-size: 14px;
}
.material-filters select {
  min-height: 42px;
  max-width: 100%;
  padding: 8px 36px 8px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-site, 12px);
  background: var(--surface);
  color: var(--ink);
  font: 500 16px var(--sans);
}
.material-filters select:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}
.material-photo[hidden] {
  display: none;
}
.material-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 14px;
}
.material-photo {
  display: block;
  overflow: hidden;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 2px 10px rgba(13, 13, 15, 0.07);
  transition:
    transform 0.25s,
    box-shadow 0.25s;
  content-visibility: auto;
  contain-intrinsic-size: 210px 210px;
}
.material-photo[hidden] {
  display: none;
}
.material-photo img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  transition: transform 0.4s;
}
.material-photo:hover,
.material-photo:focus-visible {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(13, 13, 15, 0.16);
}
.material-photo:hover img {
  transform: scale(1.05);
}
.material-others {
  padding-top: 48px;
}
.material-others h2 {
  margin-bottom: 18px;
  font-size: clamp(22px, 3vw, 30px);
}
.material-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.material-chips a {
  padding: 10px 18px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 1px 4px rgba(13, 13, 15, 0.08);
  font: 600 14px var(--sans);
  transition:
    background 0.2s,
    color 0.2s;
}
.material-chips a:hover {
  background: var(--brand, #b4231c);
  color: #fff;
}
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  background: rgba(8, 8, 10, 0.94);
}
.lightbox[hidden] {
  display: none;
}
.lightbox figure {
  margin: 0;
  text-align: center;
}
.lightbox img {
  display: block;
  max-width: min(92vw, 760px);
  max-height: 80vh;
  border-radius: 12px;
  background: #fff;
}
.lightbox figcaption {
  margin-top: 12px;
  color: #cfcfd4;
  font-size: 13px;
}
.lightbox-close {
  position: absolute;
  top: 16px;
  right: 20px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}
.lightbox-nav {
  position: absolute;
  top: 50%;
  width: 48px;
  height: 48px;
  margin-top: -24px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  cursor: pointer;
}
.lightbox-nav::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 11px;
  height: 11px;
  border-right: 3px solid #fff;
  border-bottom: 3px solid #fff;
}
.lightbox-prev {
  left: 16px;
}
.lightbox-prev::before {
  transform: translate(-30%, -50%) rotate(135deg);
}
.lightbox-next {
  right: 16px;
}
.lightbox-next::before {
  transform: translate(-70%, -50%) rotate(-45deg);
}
.lightbox-close:hover,
.lightbox-nav:hover {
  background: var(--brand, #b4231c);
}
@media (max-width: 560px) {
  .material-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .lightbox-nav {
    top: auto;
    bottom: 20px;
    margin-top: 0;
  }
}

.material-grid--ideas {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
}
.material-grid--ideas .material-photo img {
  aspect-ratio: 3 / 2;
  object-fit: contain;
}

.material-photo-title {
  display: block;
  padding: 14px 16px 16px;
  font-size: 14px;
  line-height: 1.45;
  font-weight: 600;
  color: var(--ink);
}
.material-grid--ideas .material-photo {
  content-visibility: visible;
}

.lightbox--zoom figure {
  width: min(1100px, calc(100vw - 160px));
  display: grid;
  gap: 10px;
}
.lightbox-zoom-tools {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.lightbox-zoom-tools button {
  min-width: 42px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid color-mix(in srgb, var(--paper) 35%, transparent);
  border-radius: 8px;
  background: var(--ink);
  color: var(--paper);
  font: 600 14px var(--sans);
  cursor: pointer;
}
.lightbox-zoom-tools button[data-lb-plus],
.lightbox-zoom-tools button[data-lb-minus] {
  font-size: 22px;
}
.lightbox-zoom-tools button:hover:not(:disabled) {
  background: var(--brand);
}
.lightbox-zoom-tools button:disabled {
  opacity: 0.45;
  cursor: default;
}
.lightbox-zoom-tools output {
  min-width: 56px;
  color: var(--paper);
  font: 600 13px var(--sans);
  font-variant-numeric: tabular-nums;
}
.lightbox-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: min(66dvh, 800px);
  overflow: hidden;
  border-radius: 12px;
  touch-action: none;
  user-select: none;
}
.lightbox--zoom .lightbox-stage img {
  flex: 0 0 auto;
  max-width: none;
  max-height: none;
  border-radius: 0;
  cursor: zoom-in;
  will-change: transform;
}
.lightbox-stage.is-zoomed img {
  cursor: grab;
}
.lightbox-stage.is-dragging img {
  cursor: grabbing;
}
.lightbox-zoom-help {
  margin: 0;
  color: var(--paper);
  font-size: 12px;
  line-height: 1.5;
}
.lightbox--zoom figcaption {
  margin: 0;
  line-height: 1.45;
}
.lightbox-image-status {
  position: absolute;
  padding: 20px;
  color: var(--paper);
  font-size: 14px;
}
.lightbox-zoom-tools button:focus-visible,
.lightbox-stage:focus-visible {
  outline: 2px solid var(--paper);
  outline-offset: 3px;
}
@media (max-width: 560px) {
  .lightbox--zoom figure {
    width: calc(100vw - 28px);
    padding-bottom: 48px;
  }
  .lightbox-stage {
    height: 56dvh;
  }
  .lightbox--zoom figcaption {
    padding-inline: 8px;
    font-size: 12px;
  }
}

.lightbox-nav[hidden] {
  display: none;
}
.laser-photo-open {
  display: block;
  cursor: zoom-in;
}

.lightbox-zoom-tools button[aria-pressed="true"] {
  background: var(--paper);
  color: var(--ink);
}
.lightbox--zoom .lightbox-stage img {
  cursor: default;
}
.lightbox-stage.is-magnifying img {
  cursor: crosshair;
}
.lightbox-lens {
  position: absolute;
  pointer-events: none;
  border: 2px solid var(--paper);
  border-radius: 50%;
  background-color: var(--paper);
  background-repeat: no-repeat;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
}
.lightbox-lens[hidden] {
  display: none;
}

.lightbox-loupe-toggle {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.18);
  cursor: pointer;
}
.lightbox-loupe-toggle[aria-pressed="true"] {
  background: var(--ink);
  color: var(--paper);
}
.lightbox-loupe-toggle[aria-pressed="true"] .loupe-plus {
  display: none;
}
.lightbox-loupe-toggle:focus-visible {
  outline: 2px solid var(--paper);
  outline-offset: 3px;
}
.lightbox-loupe-toggle:disabled {
  opacity: 0.45;
  cursor: default;
}

.lightbox--zoom .lightbox-stage img {
  cursor: zoom-in;
}
.lightbox-stage.is-enlarged img {
  cursor: zoom-out;
}
