/* Source-grounded photographic homepage hero. */
.hero.hero-photo-banner {
  position: relative;
  display: block;
  min-height: 470px;
  padding: 0;
  background: #111;
  isolation: isolate;
}

.hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-photo-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(90deg, rgba(8, 13, 22, .74) 0%, rgba(8, 13, 22, .57) 30%, rgba(8, 13, 22, .12) 56%, rgba(8, 13, 22, 0) 76%);
}

.hero-copy {
  position: relative;
  z-index: 1;
  width: min(560px, 50%);
  margin-left: 10vw;
  padding: 88px 0 82px;
  color: #fff;
}

.hero-copy .eyebrow { color: #d9e5ff; }
.hero-copy h1 { margin: 18px 0; font-size: 60px; letter-spacing: -.055em; }
.hero-copy p:not(.eyebrow) { color: #fff; font-size: 18px; text-shadow: 0 1px 16px rgba(0, 0, 0, .5); }
.hero-cta { padding: 14px 28px; border: 2px solid #fff; background: transparent; }
.hero-cta:hover,
.hero-cta:focus-visible { background: #fff; color: #172033; }

@media (max-width: 800px) {
  .hero.hero-photo-banner { min-height: 520px; }
  .hero-photo { object-position: 66% center; }
  .hero-photo-banner::after { background: linear-gradient(90deg, rgba(8, 13, 22, .82), rgba(8, 13, 22, .48) 68%, rgba(8, 13, 22, .16)); }
  .hero-copy { width: auto; margin: 0; padding: 82px 7vw 72px; }
  .hero-copy h1 { font-size: 48px; }
  .hero-copy p:not(.eyebrow) { max-width: 320px; font-size: 16px; }
}

@media (max-width: 430px) {
  .hero.hero-photo-banner { min-height: 500px; }
  .hero-photo { object-position: 61% center; }
  .hero-copy { padding-top: 68px; }
  .hero-copy h1 { font-size: 44px; }
}

/* Project gallery: real local product photos, never empty placeholder tiles. */
.project-gallery {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, .55fr);
  gap: 26px;
  margin: 34px 7vw 8px;
  padding: 26px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: 0 14px 34px rgba(23, 32, 51, .06);
}
.project-gallery-showcase,
.project-gallery-flow { min-width: 0; }
.project-gallery-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}
.project-gallery-heading h2 { margin: 8px 0 0; font-size: 31px; }
.project-gallery-heading > p { margin: 0; max-width: 265px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.project-gallery-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) repeat(2, minmax(120px, .72fr));
  gap: 10px;
}
.project-gallery-tile {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  min-width: 0;
  overflow: hidden;
  background: #f4f7fb;
  border: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.project-gallery-tile:hover { border-color: #9eb4ee; box-shadow: 0 8px 18px rgba(23, 32, 51, .1); transform: translateY(-2px); }
.project-gallery-tile img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  min-height: 0;
  object-fit: contain;
  background: #fff;
  padding: 10px;
}
.project-gallery-tile--hero img { aspect-ratio: 1.35 / 1; }
.project-gallery-tile span { display: block; padding: 10px 11px 12px; color: var(--muted); font-size: 10px; line-height: 1.4; }
.project-gallery-flow { padding: 6px 8px 8px 20px; background: #172033; color: #fff; }
.project-gallery-flow .eyebrow { color: #9eb7f6; }
.project-gallery-flow h3 { margin: 7px 0 9px; font-size: 24px; letter-spacing: -.03em; }
.project-gallery-flow > p:not(.eyebrow) { color: #c6d0e0; font-size: 12px; line-height: 1.5; }
.project-gallery-flow ol { display: grid; gap: 14px; margin: 20px 0 0; padding: 0; list-style: none; counter-reset: gallery-step; }
.project-gallery-flow li { display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 8px; counter-increment: gallery-step; }
.project-gallery-flow li::before { content: counter(gallery-step, decimal-leading-zero); display: grid; place-items: center; width: 24px; height: 24px; border: 1px solid #61728e; border-radius: 50%; color: #dbe6ff; font-size: 9px; }
.project-gallery-flow li b { display: block; font-size: 11px; }
.project-gallery-flow li span { display: block; margin-top: 3px; color: #aebbd0; font-size: 10px; line-height: 1.35; }
@media (max-width: 900px) {
  .project-gallery { grid-template-columns: 1fr; margin-left: 7vw; margin-right: 7vw; }
  .project-gallery-flow { padding: 22px; }
}
@media (max-width: 560px) {
  .project-gallery { margin: 22px 7vw 8px; padding: 16px; }
  .project-gallery-heading { display: block; }
  .project-gallery-heading > p { margin-top: 10px; }
  .project-gallery-heading h2 { font-size: 27px; }
  .project-gallery-grid { grid-template-columns: 1fr 1fr; }
  .project-gallery-tile--hero { grid-column: 1 / -1; }
  .project-gallery-tile--hero img { aspect-ratio: 1.25 / 1; }
}

.home-shop-overview {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 34px;
  padding: 34px 7vw 8px;
  align-items: start;
}

.home-shop-overview > * { min-width: 0; }

.popular-products {
  border: 1px solid var(--line);
  background: #fff;
  min-width: 0;
  overflow: hidden;
}

.popular-products h2 {
  margin: 0;
  padding: 23px 25px;
  border-bottom: 1px solid var(--line);
  font-size: 23px;
  letter-spacing: -.025em;
}

.popular-products nav {
  display: grid;
  grid-column: auto;
  gap: 0;
  padding: 10px 25px 20px;
  border: 0;
  min-width: 0;
  max-width: 100%;
}

.popular-products nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 0;
  color: var(--ink);
  text-decoration: none;
  font-size: 13px;
}

.popular-products nav a > img {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  opacity: .42;
}

.popular-products .popular-label { flex: 1 1 auto; }
.popular-products .popular-arrow { flex: 0 0 auto; }

.popular-products nav a:hover,
.popular-products nav a:focus-visible { color: var(--blue); }
.popular-products nav .popular-arrow { color: var(--blue); }
.home-shop-rails { min-width: 0; max-width: 100%; overflow: hidden; }
.home-shop-rails .product-rail-section { min-width: 0; }
.home-shop-rails .product-rail-section { padding: 0 0 42px; }
.home-shop-rails .rail-muted { margin: 0 -12px; padding: 34px 12px 42px; }
.home-shop-rails .section-head { margin-bottom: 22px; }
.home-shop-rails .section-head h2 { font-size: 31px; }

.home-shop-rails .rail-grid {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(170px, calc((100% - 36px) / 4));
  gap: 12px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: thin;
  padding-bottom: 10px;
  width: 100%;
  max-width: 100%;
}

.home-shop-rails .rail-card {
  min-width: 0;
  border: 1px solid var(--line);
  background: #fff;
  scroll-snap-align: start;
}

.home-shop-rails .rail-card > a {
  display: block;
  color: inherit;
  text-decoration: none;
}

.home-shop-rails .rail-visual {
  display: grid;
  min-height: 178px;
  place-items: center;
  padding: 14px;
  background: #f2f1ee;
}

.home-shop-rails .rail-visual .rail-image {
  width: 100%;
  height: 148px;
  padding: 10px;
  object-fit: contain;
  background: #fff;
}

.home-shop-rails .rail-visual > span,
.home-shop-rails .rail-visual > strong { display: none; }
.home-shop-rails .rail-copy { padding: 15px 16px 12px; }
.home-shop-rails .rail-copy small { color: var(--muted); font-size: 10px; }
.home-shop-rails .rail-copy h3 { min-height: 38px; margin: 8px 0; font-size: 17px; }
.home-shop-rails .rail-copy p { display: none; }
.home-shop-rails .rail-copy b { display: block; min-height: 32px; font-size: 11px; line-height: 1.4; }
.home-shop-rails .rail-copy > span { display: block; margin-top: 9px; color: var(--blue); font-size: 10px; font-weight: bold; }
.home-shop-rails .rail-card .quick-add { width: calc(100% - 32px); margin: 0 16px 16px; }

@media (max-width: 900px) {
  .home-shop-overview { grid-template-columns: 1fr; padding: 34px 7vw 8px; }
  .popular-products nav { display: flex; overflow-x: auto; gap: 8px; padding: 14px 18px 18px; scroll-snap-type: x proximity; }
  .popular-products nav a { flex: 0 0 auto; padding: 10px 13px; border: 1px solid var(--line); scroll-snap-align: start; }
  .popular-products nav .popular-arrow { display: none; }
  .popular-products nav a > img { width: 18px; height: 18px; flex-basis: 18px; }
  .home-shop-rails .rail-grid { grid-auto-columns: minmax(220px, 72%); }
}

/* Category cards: replace the former solid-color blocks with real local product
   photography while keeping the existing card links and copy unchanged. */
.categories .visual {
  position: relative;
  height: 190px;
  padding: 0;
  overflow: hidden;
  background: #eef2f7;
}
.categories .visual img {
  display: block;
  width: 100%;
  height: 100%;
  /* 保留整张产品图，避免窄版素材在卡片中被裁掉。 */
  object-fit: contain;
  object-position: center;
}
.categories .visual::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(23,32,51,.04), rgba(23,32,51,.22));
}
.categories .visual span {
  position: absolute;
  z-index: 1;
  top: 14px;
  left: 14px;
  color: #fff;
  font-size: 11px;
  letter-spacing: .12em;
  text-shadow: 0 1px 4px rgba(0,0,0,.35);
}

/* The NEW & UPDATED / BEST DEALS rails sit outside .home-shop-overview.  Keep
   the same card treatment there too; otherwise direct file previews render
   their generated markup as an unstyled list of text and full-width buttons. */
.product-rail-section {
  min-width: 0;
  padding: 62px 7vw 70px;
  background: #fff;
  border-top: 1px solid var(--line);
}
.product-rail-section > .section-head {
  max-width: 1280px;
  margin: 0 auto 22px;
}
.product-rail-section > .rail-grid {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(205px, 240px);
  gap: 14px;
  width: min(1280px, 100%);
  margin: 0 auto;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: thin;
  padding: 2px 2px 12px;
}
.product-rail-section > .rail-grid > .rail-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: 0 4px 14px rgba(23,32,51,.06);
  scroll-snap-align: start;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.product-rail-section > .rail-grid > .rail-card:hover {
  border-color: #a8bceb;
  box-shadow: 0 10px 24px rgba(23,32,51,.12);
  transform: translateY(-3px);
}
.product-rail-section .rail-card > a {
  display: block;
  color: inherit;
  text-decoration: none;
}
.product-rail-section .rail-visual {
  position: relative;
  display: grid;
  gap: 8px;
  min-height: 190px;
  padding: 12px;
  background: #f2f5fa;
}
.product-rail-section .rail-image {
  display: block;
  width: 100%;
  height: 158px;
  padding: 10px;
  object-fit: contain;
  background: #fff;
}
.product-rail-section .rail-visual > span {
  position: absolute;
  top: 9px;
  left: 10px;
  color: var(--blue);
  font-size: 10px;
  font-weight: 700;
}
.product-rail-section .rail-visual > strong {
  display: block;
  min-height: 30px;
  color: var(--ink);
  font-size: 11px;
  line-height: 1.3;
}
.product-rail-section .rail-copy {
  display: grid;
  gap: 7px;
  padding: 14px 15px 16px;
}
.product-rail-section .rail-copy small {
  color: var(--muted);
  font-size: 10px;
}
.product-rail-section .rail-copy h3 {
  min-height: 38px;
  margin: 0;
  font-size: 16px;
  line-height: 1.25;
}
.product-rail-section .rail-copy p {
  min-height: 45px;
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}
.product-rail-section .rail-copy b {
  min-height: 30px;
  font-size: 11px;
  line-height: 1.35;
}
.product-rail-section .rail-copy > span {
  color: var(--blue);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .04em;
}
.product-rail-section .rail-card .quick-add {
  width: calc(100% - 30px);
  margin: 0 15px 15px;
}
@media (max-width: 900px) {
  .product-rail-section { padding: 48px 7vw 56px; }
  .product-rail-section > .rail-grid { grid-auto-columns: minmax(220px, 72vw); }
}
@media (max-width: 560px) {
  .categories .visual { height: 150px; }
  .product-rail-section > .rail-grid { grid-auto-columns: minmax(210px, 82vw); }
}

/* Lower homepage sections: keep the content below the product rails in a
   readable, bounded layout instead of letting headings, links and carousel
   items fall into an unstyled vertical stream. */
.social-proof,
.trust-strip,
.quality-section,
.category-browse,
.journal,
.newsletter {
  padding: 70px 7vw;
  border-top: 1px solid var(--line);
}
.social-proof { background: #f7f8fb; overflow: hidden; }
.social-proof > .section-head,
.quality-section > *,
.category-browse > .section-head,
.journal > .section-head,
.newsletter > * { max-width: 1280px; }
.social-proof > .section-head,
.category-browse > .section-head,
.journal > .section-head {
  margin-left: auto;
  margin-right: auto;
}
.proof-controls {
  display: flex;
  gap: 8px;
}
.proof-controls button,
.rail-controls button {
  width: 34px;
  height: 32px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
}
.proof-controls button:hover,
.proof-controls button:focus-visible,
.rail-controls button:hover,
.rail-controls button:focus-visible { border-color: #9eb4ee; color: var(--blue); }
.proof-stage {
  display: flex;
  width: 300%;
  margin: 0 auto;
  overflow: visible;
  transition: transform .35s ease-out;
}
.proof-stage article {
  flex: 0 0 33.333333%;
  min-height: 210px;
  padding: 32px;
  border: 1px solid var(--line);
  background: #fff;
}
.proof-stage article span,
.trust-strip > .eyebrow,
.journal-grid a > span {
  color: var(--blue);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .13em;
}
.proof-stage article h3 { margin: 20px 0 10px; font-size: 28px; letter-spacing: -.03em; }
.proof-stage article p { max-width: 560px; margin: 0; color: var(--muted); line-height: 1.6; }
.trust-strip { background: #fff; text-align: center; }
.trust-strip > div {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  max-width: 1280px;
  margin: 22px auto 0;
  border: 1px solid var(--line);
}
.trust-strip > div b {
  display: grid;
  place-items: center;
  min-height: 66px;
  padding: 12px;
  color: var(--ink);
  font-size: 12px;
  letter-spacing: .06em;
  border-right: 1px solid var(--line);
}
.trust-strip > div b:last-child { border-right: 0; }
.quality-section {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  gap: 45px;
  align-items: start;
  background: #f7f8fb;
}
.quality-section > div:first-child { max-width: 520px; }
.quality-section h2 { margin: 12px 0; font-size: 42px; }
.quality-section > div:first-child > p:not(.eyebrow) { color: var(--muted); line-height: 1.6; }
.quality-section > div:first-child > a { color: var(--blue); font-size: 12px; font-weight: 700; }
.quality-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.quality-grid article {
  min-height: 175px;
  padding: 22px;
  border: 1px solid var(--line);
  background: #fff;
}
.quality-grid article > b { color: var(--blue); font-size: 11px; letter-spacing: .1em; }
.quality-grid h3 { margin: 30px 0 10px; font-size: 17px; }
.quality-grid p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.category-browse { background: #fff; }
.category-links {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  max-width: 1280px;
  margin: 0 auto;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}
.category-links a {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 20px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
  font-size: 13px;
}
.category-links a span { color: var(--blue); font-weight: 800; }
.category-links a:hover,
.category-links a:focus-visible { background: #f5f8ff; color: var(--blue); }
.journal { background: #f7f8fb; }
.journal-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  max-width: 1280px;
  margin: 0 auto;
}
.journal-grid a {
  min-height: 210px;
  padding: 26px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.journal-grid a:hover,
.journal-grid a:focus-visible { border-color: #a8bceb; box-shadow: 0 8px 20px rgba(23,32,51,.08); transform: translateY(-2px); }
.journal-grid h3 { margin: 22px 0 10px; font-size: 20px; letter-spacing: -.02em; }
.journal-grid p { margin: 0; color: var(--muted); line-height: 1.5; }
.newsletter {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 35px;
  background: #172033;
  color: #fff;
}
.newsletter .eyebrow { color: #9eb7f6; }
.newsletter h2 { margin: 12px 0 8px; font-size: 36px; }
.newsletter p:not(.eyebrow) { margin: 0; color: #c6d0e0; }
.newsletter form { display: grid; grid-template-columns: minmax(220px, 1fr) auto; gap: 10px; width: min(510px, 100%); }
.newsletter input { min-width: 0; border: 0; padding: 14px; font: inherit; }
.newsletter small { grid-column: 1 / -1; color: #c6d0e0; }
@media (max-width: 900px) {
  .quality-section { grid-template-columns: 1fr; gap: 28px; }
  .category-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .journal-grid { grid-template-columns: 1fr 1fr; }
  .newsletter { display: grid; align-items: start; }
  .newsletter form { width: 100%; }
}
@media (max-width: 560px) {
  .social-proof,
  .trust-strip,
  .quality-section,
  .category-browse,
  .journal,
  .newsletter { padding: 50px 7vw; }
  .proof-stage article { padding: 24px; min-height: 190px; }
  .proof-stage article h3 { font-size: 23px; }
  .trust-strip > div,
  .quality-grid,
  .category-links,
  .journal-grid { grid-template-columns: 1fr; }
  .trust-strip > div b { border-right: 0; border-bottom: 1px solid var(--line); }
  .trust-strip > div b:last-child { border-bottom: 0; }
  .newsletter form { grid-template-columns: 1fr; }
  .newsletter small { grid-column: auto; }
}
