/* Shared corrections from the approved homepage. Loaded after each page's own styles. */
body nav {
  height: 86px !important;
  padding-inline: max(32px, calc((100vw - 1320px) / 2)) !important;
  background: rgba(255, 255, 255, .97) !important;
  border-bottom: 1px solid #d8e0e9 !important;
}
body nav .brand {
  width: 156px !important;
  height: 56px !important;
  flex: 0 0 156px !important;
}
body nav .brand img { width: 100% !important; height: auto !important; max-height: 56px !important; }
body nav .links { gap: 23px; font-size: 12px; font-weight: 700; letter-spacing: .03em; }
body nav .cta {
  padding: 11px 17px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.55;
  letter-spacing: .02em;
  background: #13345d !important;
  color: #fff !important;
  border-color: #13345d !important;
}
.full-footer { background: #fff !important; padding: 58px 0 20px !important; }
.full-footer .foot-grid { grid-template-columns: 1.05fr .95fr .8fr 1.5fr !important; gap: 34px !important; }
.full-footer .brand { width: 144px !important; height: 54px !important; }
.full-footer .brand img { width: 144px !important; max-height: 54px !important; }
.full-footer .foot-grid h4 { margin: 3px 0 15px !important; }
.full-footer .foot-grid a, .full-footer .foot-grid p, .full-footer .foot-grid address {
  font-size: 13px !important;
  line-height: 1.55;
  color: #52657e !important;
}
.full-footer .foot-grid address { margin: 13px 0 0; font-style: normal; }
.full-footer .footer-contact p { margin: 0 0 6px !important; }
/* Root tokens alone cannot override a library page's own inherited custom properties. */
body.library-page {
  --library-surface: #faf9f6;
  --library-wash: #eaf0f8;
  --library-ink: #13345d;
  --library-muted: #637187;
  --library-line: #d8e0e9;
  --library-accent: #315b95;
  background: #faf9f6;
  color: #13345d;
}
body.product-page, body.k1-sample { background: #faf9f6 !important; color: #13345d; }
body.product-page .product-detail, body.k1-sample .product-detail { background: #faf9f6 !important; }
body .detail-note { background: #fff !important; color: #637187 !important; border: 1px solid #d8e0e9; }
body .detail-gallery img, body .template-gallery div { background: #fff !important; }
.enquiry-form input::placeholder, .enquiry-form textarea::placeholder { color: #6d7784; opacity: 1; font-weight: 400; }
.enquiry-form select:has(option[value=""]:checked) { color: #6d7784; font-weight: 400; }
body .enquiry-form button:disabled { background: #e8edf3; color: #637187; border-color: #d8e0e9; }
@media (min-width: 981px) {
  .library-page .family-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; }
  .library-page .family-card, .library-page .family-card:nth-child(2), .library-page .family-card:nth-child(3) {
    min-height: 480px;
    height: 480px;
    align-self: stretch;
  }
  .library-page .family-card img { width: 100%; height: 100%; object-fit: cover; }
  .library-page .family-card h3 { font-size: clamp(29px, 2.5vw, 36px); line-height: 1.04; letter-spacing: -.035em; }
}
/* Keep the existing narrow-screen treatment; detailed device adaptation is deferred. */
@media (max-width: 980px) {
  body nav .links { gap: 14px; font-size: 11px; }
  body nav .brand { width: 136px !important; flex-basis: 136px !important; }
  .full-footer .foot-grid { grid-template-columns: 1fr 1fr !important; }
}
@media (max-width: 780px) {
  body nav { height: 72px !important; padding-inline: 20px !important; }
  body nav .brand { width: 124px !important; height: 46px !important; flex-basis: 124px !important; }
  body nav .brand img { max-height: 46px !important; }
  .full-footer .foot-grid { grid-template-columns: 1fr 1fr !important; gap: 27px 20px !important; }
  .full-footer .foot-grid > div:first-child, .full-footer .footer-contact { grid-column: 1 / -1 !important; }
}

/* Products family-card correction: equal media + copy panels, independent of title wraps. */
.products-page .family-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; }
.products-page .family-card:nth-child(n) {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  align-self: stretch !important;
  height: auto !important;
  min-height: 0 !important;
  padding: 0;
  background: #13345d !important;
}
.products-page .family-card::after { display: none; }
.products-page .family-card__image {
  position: relative;
  flex: 0 0 auto;
  width: 100%;
  height: auto;
  aspect-ratio: 9 / 8;
  overflow: hidden;
  background: #13345d;
}
.products-page .family-card .family-card__image img {
  position: absolute;
  inset: auto;
  left: 50%;
  top: 50%;
  width: auto;
  height: var(--scene-height);
  max-width: none;
  object-fit: fill;
  object-position: center;
  transform: translate(var(--subject-offset-x), var(--subject-offset-y));
}
.products-page .family-card--noise {
  --scene-height: 212.932%;
  --subject-offset-x: -55.52%;
  --subject-offset-y: -52.35%;
}
.products-page .family-card--wake {
  --scene-height: 130.435%;
  --subject-offset-x: -56.16%;
  --subject-offset-y: -52.06%;
}
.products-page .family-card--clock {
  --scene-height: 130.719%;
  --subject-offset-x: -62.01%;
  --subject-offset-y: -38.5%;
}
.products-page .family-card .family-card__number {
  top: 16px;
  left: 18px;
  padding: 3px 6px;
  background: rgba(19,52,93,.75);
  color: #fff;
  font-size: 10px;
}
.products-page .family-card__copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  flex: 1 0 190px;
  min-height: 190px;
  padding: 23px 25px 24px;
  background: #13345d;
  color: #fff;
}
.products-page .family-card__copy p {
  min-height: 16px;
  margin: 0 0 11px;
  color: #d7e1ef;
  font-size: 11px;
  line-height: 16px;
  letter-spacing: .045em;
}
.products-page .family-card__copy h3 {
  width: 100%;
  min-height: 58px;
  margin: 0 0 18px;
  color: #fff;
  font-size: 25px;
  line-height: 29px;
  letter-spacing: -.025em;
}
.products-page .family-card__link { margin-top: auto; color: #fff; font-size: 12px; line-height: 18px; }
@media(max-width:780px) { .products-page .family-grid { grid-template-columns: 1fr; } }

/* Company: Packaging item removed at the user's request; do not leave a gap. */
.company-page .proof-gallery .wrap { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.company-page .proof-gallery .company-photo {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: #faf9f6;
}
@media(max-width:780px) { .company-page .proof-gallery .wrap { grid-template-columns: 1fr; } }
