/* Holden's Latex - Informational Site Stylesheet (vanilla CSS) */

:root {
  --hx-red: #ed1c24;
  --hx-red-dark: #992727;
  --ink: #1a1a1a;
  --slate: #4a4a4a;
  --muted: #6b7280;
  --line: #e5e7eb;
  --bg: #fff;
  --bg-soft: #f7f7f5;
  --bg-dark: #1c1f24;
  --gold: #d9a441;
  --radius: 10px;
  --shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 8px 28px rgba(0, 0, 0, 0.1);
  --maxw: 1140px;
  --font: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

@view-transition {
  navigation: auto;
}


/* 3. Contain layout shift issues */
html, body {
  /* Prevents full-page layout calculation bugs during the transition */
  contain: layout; 
   margin: 0;
  padding: 0;
}


/* 4. Isolate the main content for the slide animation */
main {
  view-transition-name: main-content;
}

/* 3. Put the overflow containment strictly on the wrapper */
.page-container {
  overflow-x: hidden; 
  width: 100%;
}
/* Apply the slide-out animation to the exiting page */
::view-transition-old(main-content) {
  animation: 0.4s ease-in-out both slide-out;
}

/* Apply the slide-in animation to the entering page */
::view-transition-new(main-content) {
  animation: 0.4s ease-in-out both slide-in;
}
/* Outgoing page slides out to the left */
@keyframes slide-out {
  from { transform: translateX(0); }
  to { transform: translateX(-100%); }
}

/* Incoming page slides in from the right */
@keyframes slide-in {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

::view-transition-group(featured-product-image) {
  animation-duration: 420ms;
  animation-timing-function: cubic-bezier(0.2, 0.72, 0, 1);
}

::view-transition-old(featured-product-image),
::view-transition-new(featured-product-image) {
  border-radius: 8px;
}

/* Product pages use a single destination target for card-image fly transitions. */
#pgMainImg {
  view-transition-name: featured-product-image;
}

@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(featured-product-image) {
    animation-duration: 1ms;
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  font-size: 17px;
}

a {
  color: var(--hx-red);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

h1,
h2,
h3 {
  line-height: 1.2;
  color: var(--ink);
}

h1 {
  font-size: 2.2rem;
  margin: 0 0 0.5rem;
}

h2 {
  font-size: 1.6rem;
  margin: 0 0 1rem;
}

h3 {
  font-size: 1.2rem;
  margin: 0 0 0.5rem;
}

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 22px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #fff;
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow);

  view-transition-name: site-header;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 22px;
  max-width: var(--maxw);
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand:hover {
  text-decoration: none;
}

.brand-logo {
  display: block;
  height: 46px;
  width: auto;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.nav-links a {
  color: var(--slate);
  font-size: 0.93rem;
  font-weight: 600;
  padding: 8px 12px;
  border-radius: 6px;
}

.nav-links a:hover {
  background: var(--bg-soft);
  color: var(--hx-red);
  text-decoration: none;
}

.nav-links a.active {
  color: var(--hx-red);
}

.btn {
  display: inline-block;
  background: var(--hx-red);
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 10px 18px;
  border-top-left-radius: 10px;
  border-bottom-right-radius: 10px;
  border: 2px solid var(--hx-red);
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn:hover {
  background: var(--hx-red-dark);
  border-color: var(--hx-red-dark);
  text-decoration: none;
  color: #fff;
}

.btn-ghost {
  background: transparent;
  color: var(--hx-red);
}

.btn-ghost:hover {
  background: var(--hx-red);
  color: #fff;
}

.btn-sm {
  padding: 7px 14px;
  font-size: 0.85rem;
}

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  font-size: 1.6rem;
  cursor: pointer;
  color: var(--ink);
}

.nav-links a.btn {
  color: #fff;
  background: var(--hx-red);
  border-color: var(--hx-red);
  border-top-left-radius: 10px;
  border-bottom-right-radius: 10px;
  border-top-right-radius: 0px;
  border-bottom-left-radius: 0px;
}

.nav-links a.btn:hover {
  color: #fff;
  background: var(--hx-red-dark);
  border-color: var(--hx-red-dark);
}

/* Hero - background matches the banner image's edge color for a seamless blend */
.hero {
  position: relative;
  background: #181818;
  color: #fff;
  padding: 16px 0;
  overflow: hidden;
}

.hero h1 {
  color: #fff;
  font-size: 2.7rem;
  max-width: 16ch;
}

.hero .lede {
  font-size: 1.2rem;
  color: #d7d7d7;
  max-width: 52ch;
  margin: 1rem 0 1.8rem;
}

.hero .eyebrow {
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.8rem;
  font-weight: 700;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.hero .btn-ghost {
  color: #fff;
  border-color: #fff;
}

.hero .btn-ghost:hover {
  background: #fff;
  color: var(--ink);
}

/* Two-column hero: text left, product lineup image beside it. Image self-fades on all edges into #181818. */
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 0.9fr;
  gap: 24px;
  align-items: center;
}

.hero-copy {
  min-width: 0;
}

.hero-figure {
  margin: 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-figure img {
  display: block;
  width: 100%;
  max-width: 560px;
  height: auto;
}

.section {
  padding: 60px 0;
}

.section.soft {
  background: var(--bg-soft);
}

.section-head {
  text-align: center;
  max-width: 62ch;
  margin: 0 auto 2.4rem;
}

.section-head p {
  color: var(--muted);
  font-size: 1.05rem;
}

.eyebrow-c {
  text-align: center;
  color: var(--hx-red);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.78rem;
  font-weight: 800;
  margin-bottom: 0.4rem;
}

.grid {
  display: grid;
  gap: 22px;
}

.grid-2 {
  grid-template-columns: repeat(2, 1fr);
}

.grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.card .tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--hx-red);
  background: #fdeef0;
  padding: 3px 9px;
  border-radius: 20px;
  margin-bottom: 10px;
  align-self: flex-start;
}

.card h3 {
  margin-bottom: 0.35rem;
}

.card .sku {
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: 700;
  letter-spacing: 0.5px;
}

.card p {
  color: var(--slate);
  font-size: 0.95rem;
  margin: 0.5rem 0 1rem;
}

.card .card-foot {
  margin-top: auto;
}

.card-img {
  background: #fff;
  border-radius: 8px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-bottom: 0px;
}

.products .card-img{
  padding-bottom:0px;
}

.products .related-grid .card-img{
  padding:0px;
}

.card-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 10px;
}

.feature {
  text-align: center;
  padding: 10px;
}

.feature .ico {
  width: 58px;
  height: 58px;
  margin: 0 auto 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--hx-red);
  color: #fff;
  border-radius: 50%;
  font-size: 1.5rem;
  font-weight: 800;
}

.feature h3 {
  margin-bottom: 0.3rem;
}

.feature p {
  color: var(--muted);
  font-size: 0.95rem;
}

.buy-band {
  background: var(--hx-red);
  color: #fff;
  border-radius: 14px;
  padding: 40px;
  text-align: center;
}

.buy-band h2 {
  color: #fff;
}

.buy-band p {
  color: #ffe3e7;
  max-width: 60ch;
  margin: 0.5rem auto 1.6rem;
  font-size: 1.05rem;
}

.buy-band .btn {
  background: #fff;
  color: var(--hx-red);
  border-color: #fff;
  font-size: 1.05rem;
  padding: 13px 26px;
}

.buy-band .btn:hover {
  background: #1c1f24;
  color: #fff;
  border-color: #1c1f24;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  background: #fff;
}

th,
td {
  text-align: left;
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
}

th {
  background: var(--bg-soft);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--slate);
}

tr:last-child td {
  border-bottom: 0;
}

tbody tr:hover {
  background: #fafafa;
}

.page-head {
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
  padding: 46px 0;
}

.products .page-head {
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
}

.page-head .eyebrow {
  color: var(--hx-red);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.78rem;
  font-weight: 800;
}

.page-head h1 {
  margin: 0.3rem 0 0.4rem;
}

.page-head p {
  color: var(--muted);
  max-width: 70ch;
  margin: 0;
}

.crumb {
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 0.6rem;
}

.crumb a {
  color: var(--muted);
}

.faq details {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 4px 20px;
  margin-bottom: 12px;
  box-shadow: var(--shadow);
}

.faq summary {
  cursor: pointer;
  font-weight: 700;
  padding: 14px 0;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  color: var(--hx-red);
  font-size: 1.4rem;
  font-weight: 700;
}

.faq details[open] summary::after {
  content: "\2013";
}

.faq details p {
  color: var(--slate);
  margin: 0 0 16px;
}

.split {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}

.split ul {
  padding-left: 18px;
}

.split li {
  margin-bottom: 0.5rem;
  color: var(--slate);
}

.panel {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
}

.panel h3 {
  color: var(--hx-red);
}

.pill-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.pill-list li {
  background: #f7f7f5;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 7px 15px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--slate);
}

.site-footer {
  background: var(--bg-dark);
  color: #cfd3d8;
  padding: 52px 0 26px;
  font-size: 0.92rem;
}

.site-footer h4 {
  color: #fff;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 0 0 14px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 30px;
}

.site-footer a {
  color: #fff;
}

.site-footer a:hover {
  color: #fff;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 9px;
}

.footer-brand .logo-chip {
  display: inline-block;
  background: #fff;
  padding: 10px 14px;
  border-radius: 8px;
  margin-bottom: 14px;
  box-shadow: var(--shadow);
}

.footer-brand .logo-chip img {
  display: block;
  height: 40px;
  width: auto;
}

.footer-bottom {
  border-top: 1px solid #333;
  margin-top: 34px;
  padding-top: 18px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  color: #9aa0a6;
  font-size: 0.85rem;
}

.lead {
  font-size: 1.15rem;
  color: var(--slate);
}

.mb-0 {
  margin-bottom: 0;
}

.mt-0 {
  margin-top: 0;
}

h1,
h2,
h3,
.lead,
.hero .lede,
.section-head p,
.page-head p,
.buy-band p,
.feature p {
  text-wrap: balance;
}

p,
li,
.card p,
.prose p,
.faq details p,
.pg-lead {
  text-wrap: pretty;
}

#mold-making,
#casting-mask,
#body-cosmetic,
#colorants-additives {
  scroll-margin-top: 90px;
}

@media (max-width: 900px) {
  .grid-3,
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .split {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .hero h1 {
    font-size: 2.1rem;
  }
}

@media (max-width: 820px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .hero-figure img {
    max-width: 360px;
  }
}

@media (max-width: 640px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 74px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: #fff;
    border-bottom: 1px solid var(--line);
    padding: 10px 16px;
    box-shadow: var(--shadow-lg);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 12px;
  }

  .nav-toggle {
    display: block;
  }

  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .buy-band {
    padding: 28px 20px;
  }

  .hero {
    padding: 54px 0;
  }

  .hero h1 {
    font-size: 1.8rem;
  }
}

.product-top {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 44px;
  align-items: start;
}

.pg-main {
  background: var(--bg-soft);
  border-radius: var(--radius);
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

.pg-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pg-main.has-image {
  background: #fff;
}

.pg-main.has-image img {
  object-fit: contain;
  padding: 14px;
}

.pg-thumbs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 12px;
}

.pg-thumb {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 1.2rem;
  cursor: pointer;
  overflow: hidden;
  padding: 0;
  transition: border-color 0.15s ease;
}

.pg-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
  padding: 6px;
}

.pg-thumb.active {
  border-color: var(--hx-red);
  border-width: 2px;
}

.pg-thumb:hover {
  border-color: var(--hx-red);
}

.pg-thumbs.swatches {
  grid-template-columns: repeat(auto-fill, minmax(78px, 1fr));
  gap: 12px;
}

.pg-swatch {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

.pg-swatch .pg-thumb {
  aspect-ratio: 1 / 1;
}

.pg-swatch-label {
  display: block;
  text-align: center;
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--slate);
  margin-top: 5px;
  line-height: 1.15;
}

.pg-cat {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--hx-red);
  background: #fdeef0;
  padding: 4px 11px;
  border-radius: 20px;
  margin-bottom: 12px;
}

.pg-info h1 {
  font-size: 2.1rem;
  margin-bottom: 0.2rem;
}

.pg-sku {
  color: var(--muted);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
  margin-bottom: 18px;
}

.pg-lead {
  font-size: 1.12rem;
  color: var(--slate);
  margin-bottom: 22px;
}

.pg-buy {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 10px;
}

.pg-buy .note {
  font-size: 0.85rem;
  color: var(--muted);
}

.pg-highlights {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
}

.pg-highlights li {
  padding: 8px 0 8px 30px;
  position: relative;
  color: var(--slate);
  border-bottom: 1px solid var(--line);
}

.pg-highlights li:last-child {
  border-bottom: 0;
}

.pg-highlights li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  top: 8px;
  color: var(--hx-red);
  font-weight: 800;
}

.spec-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.spec-table th,
.spec-table td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
}

.spec-table th {
  width: 38%;
  background: var(--bg-soft);
  color: var(--slate);
  font-weight: 700;
}

.spec-table tr:last-child th,
.spec-table tr:last-child td {
  border-bottom: 0;
}

.prose {
  max-width: 760px;
}

.prose h2 {
  margin-top: 6px;
}

.prose h3 {
  margin-top: 26px;
  color: var(--hx-red);
}

.prose p {
  color: var(--slate);
}

.prose ul {
  padding-left: 20px;
}

.prose li {
  color: var(--slate);
  margin-bottom: 0.5rem;
}

.ratio-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  margin: 6px 0 4px;
}

.ratio-table th,
.ratio-table td {
  text-align: left;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
}

.ratio-table th {
  background: var(--bg-soft);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: var(--slate);
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.doc-downloads {
  margin-top: 20px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-soft);
}

.doc-downloads h3 {
  margin: 0 0 12px;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--slate);
}

.doc-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-start;
  width: 100%;
  margin-bottom: 10px;
  background: #fff;
  color: var(--hx-red);
}

.doc-btn:last-child {
  margin-bottom: 0;
}

.doc-btn:hover {
  background: var(--hx-red);
  color: #fff;
}

.feature-link {
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease,
    background 0.15s ease;
}

.feature-link:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  text-decoration: none;
}

.feature-link h3 {
  color: var(--ink);
}

.feature-cta {
  display: inline-block;
  margin-top: auto;
  padding-top: 10px;
  color: var(--hx-red);
  font-weight: 700;
  font-size: 0.9rem;
}



.feature-link:hover .feature-cta{
  text-decoration:underline;
}



@media (max-width:900px){
  .product-top{
    grid-template-columns:1fr;
    gap:26px;
  } 
  .related-grid{
    grid-template-columns:repeat(2,1fr);
  }
  .split{
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr))!important;
    .btn-group {
      display: flex;
      gap: 10px;
      flex-wrap: wrap;
    }
  }
}
@media (max-width:640px){
  .related-grid{
    grid-template-columns:1fr;
  } 
  .pg-info h1{font-size:1.7rem;}
}

/* Where to Buy: stack the distributor table into cards on small screens */
.distributors .table-wrap td a[href^="tel:"] {
  color: inherit;
  text-decoration: none;
}

@media (max-width: 640px) {
  .distributors .table-wrap {
    border: 0;
    border-radius: 0;
    overflow: visible;
  }

  .distributors .table-wrap table,
  .distributors .table-wrap tbody,
  .distributors .table-wrap tr,
  .distributors .table-wrap td {
    display: block;
    width: 100%;
  }

  .distributors .table-wrap thead {
    display: none;
  }

  .distributors .table-wrap tr {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    background: #fff;
    margin-bottom: 14px;
    padding: 6px 0;
  }

  .distributors .table-wrap tr:last-child {
    margin-bottom: 0;
  }

  .distributors .table-wrap tbody tr:hover {
    background: #fff;
  }

  .distributors .table-wrap td {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    padding: 10px 16px;
    border-bottom: 1px solid var(--line);
    font-size: 0.95rem;
    text-align: right;
  }

  .distributors .table-wrap td:last-child {
    border-bottom: 0;
  }

  .distributors .table-wrap td::before {
    content: attr(data-label);
    flex: 0 0 auto;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--muted);
    text-align: left;
  }

  /* First cell is the distributor name: give it the full row as a heading */
  .distributors .table-wrap td:first-child {
    display: block;
    text-align: left;
    font-weight: 600;
    font-size: 1.05rem;
    color: var(--ink);
    padding-top: 14px;
  }

  .distributors .table-wrap td:first-child::before {
    display: none;
  }

  .distributors .table-wrap td a {
    word-break: break-word;
  }
}
