/* ==========================================================================
   CT Alloy — gallery
   ========================================================================== */

body.gallery {
  background: #08090d;
  color: var(--silver-100);
  min-height: 100vh;
}

.gticker {
  overflow: hidden;
  background: var(--ink);
  color: rgba(255, 255, 255, .5);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.gticker__inner {
  display: flex;
  width: max-content;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .26em;
  text-transform: uppercase;
  padding: 11px 0;
  animation: ct-marq 30s linear infinite;
}

.ghead {
  max-width: 1440px;
  margin: 0 auto;
  padding: 64px 34px 30px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.ghead h1 {
  margin: 0;
  font-size: clamp(40px, 6vw, 82px);
  font-weight: 700;
  line-height: .9;
  letter-spacing: -.02em;
  text-transform: uppercase;
}
.ghead__sub {
  margin: 14px 0 0;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--steel-500);
}
.ghead__jump { display: flex; gap: 10px; flex-wrap: wrap; }
.ghead__jump a {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(238, 241, 246, .62);
  border: 1px solid rgba(238, 241, 246, .16);
  border-radius: 100px;
  padding: 10px 18px;
  transition: background .25s ease, color .25s ease, border-color .25s ease;
}
.ghead__jump a:hover { background: var(--chalk); color: var(--ink); border-color: var(--chalk); }
/* The jump row lists all three families, so each catalogue page can reach the
   other two — there is no "all rims" page to fall back to any more. The chip
   for the page you are on is filled; CT.initSiteNav() sets .is-here by matching
   the href against the current file name. */
.ghead__jump a.is-here {
  color: var(--ink);
  background: var(--chalk);
  border-color: var(--chalk);
  cursor: default;
}
/* Constructions under the current family: in-page jumps, indented behind a
   tick so they read as children of the filled family chip. */
.ghead__jump-sub {
  font-size: 12px;
  padding: 10px 15px;
  color: rgba(238, 241, 246, .5);
  border-style: dashed;
}
.ghead__jump-sub::before {
  content: '↳';
  margin-right: 7px;
  opacity: .5;
}

.gsection {
  max-width: 1440px;
  margin: 0 auto;
  padding: 26px 34px 10px;
  display: flex;
  align-items: center;
  gap: 20px;
  scroll-margin-top: 90px;
}
/* An empty construction group is taken off the page by gallery.js. `.gsection`
   sets display, which outranks the UA `[hidden]` rule, so say it explicitly. */
.gsection[hidden] { display: none; }
/* A family with one construction has no .gsection heading — the <h1> already
   says the word — so its grid wrap carries the id and needs the same anchor
   clearance under the sticky nav. */
.ggrid-wrap[id] { scroll-margin-top: 90px; }
.gsection h2,
.gsection h3 {
  margin: 0;
  font-size: clamp(30px, 4vw, 54px);
  font-weight: 700;
  letter-spacing: -.02em;
  color: var(--silver-100);
}
/* A construction inside a family is a sub-heading, so it steps down in size
   and indents under the band above it. */
.gsection--sub { padding: 22px 34px 8px; }
/* h2, not h3: a construction is a section of its family's page, and the page's
   <h1> is the family. It was an h3 when it sat under a .gfamily <h2>. */
.gsection--sub h2,
.gsection--sub h3 {
  font-size: clamp(17px, 1.7vw, 23px);
  letter-spacing: .01em;
  color: rgba(238, 241, 246, .88);
}
.gsection--sub .gsection__note { font-size: 11px; }
.gsection__rule {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(238, 241, 246, .24), rgba(238, 241, 246, 0));
}
.gsection__note {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: rgba(238, 241, 246, .42);
  white-space: nowrap;
}

.ggrid-wrap { max-width: 1440px; margin: 0 auto; padding: 16px 34px 60px; }
.ggrid-wrap--last { padding-bottom: 90px; }
.ggrid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 26px;
}

/* Gallery cards square off the product stage and add an expandable spec panel. */
.gallery .rim-card__name { font-size: 20px; }
.gallery .rim-card__body { gap: 12px; padding-bottom: 22px; }

.rim-card__specs { display: flex; flex-direction: column; gap: 12px; }
.rim-card__specs[hidden] { display: none; }
.rim-card__specs .modal__label {
  font-size: 10px;
  letter-spacing: .22em;
  color: rgba(12, 15, 20, .4);
}
.rim-card__sizes { display: flex; flex-wrap: wrap; gap: 6px; }
.rim-card__buy {
  margin-top: 2px;
  width: 100%;
  padding: 13px 18px;
  border: none;
  border-radius: 12px;
  background: var(--ink);
  color: #fff;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .2em;
  text-transform: uppercase;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background .25s ease, transform .2s ease;
}
.rim-card__buy:hover { background: var(--ink-500); transform: translateY(-1px); }

@media (max-width: 760px) {
  /* .gsection__note is nowrap and pushes its row wider than the viewport once
     the heading grows — drop it rather than let the page scroll sideways. */
  .gsection__note { display: none; }
}

@media (max-width: 640px) {
  .ghead { padding: 40px 18px 22px; }
  .gsection { padding: 22px 18px 8px; }
  .ggrid-wrap { padding: 12px 18px 44px; }
  .ggrid { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 18px; }
}
