/* Materials library and certificate of provenance (assets/js/materials.js). Loaded after shell.css.
   Palette: cream, dark green, cobalt, yellow, black. */
:root {
  --ms-cream: #f7f3ea;
  --ms-green: #134e3a;
  --ms-cobalt: #1e3fa6;
  --ms-yellow: #f2c230;
  --ms-ink: #121212;
  --ms-line: rgba(18, 18, 18, .14);
}

/* ---------------- page ---------------- */
.ms-page { padding-bottom: 120px; }
.ms-head { padding: clamp(28px, 5vw, 64px) 0 clamp(20px, 3vw, 32px); max-width: 860px; }
.ms-head h1 { font-family: var(--font-house, inherit); font-size: clamp(34px, 5vw, 68px); line-height: 1.02; letter-spacing: -0.04em; font-weight: 500; margin: 10px 0 16px; text-wrap: balance; color: var(--ms-ink); }
.ms-intro { font-size: clamp(16px, 1.3vw, 18px); line-height: 1.55; color: #2a2a2a; max-width: 640px; margin: 0; }

.ms-choose { background: var(--ms-green); color: #fff; padding: clamp(22px, 3.4vw, 40px); margin: 8px 0 clamp(28px, 4vw, 44px); }
.ms-choose h2 { font-size: clamp(24px, 2.6vw, 34px); font-weight: 500; letter-spacing: -0.03em; margin: 0 0 18px; color: #fff; text-transform: none; }
.ms-choose-cols { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(18px, 3vw, 40px); }
.ms-choose-cols p { margin: 0; font-size: 16px; line-height: 1.55; color: rgba(255, 255, 255, .92); }
.ms-choose-cols .ms-choose-k { font: 600 13px/1.2 Inter, system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; color: var(--ms-yellow); margin-bottom: 8px; }
.ms-choose-links { display: flex; flex-wrap: wrap; gap: 10px; margin: 22px 0 0; }
.ms-choose-links a { display: inline-block; padding: 11px 16px; background: var(--ms-cream); color: var(--ms-ink); text-decoration: none; font: 500 14px/1 Inter, system-ui, sans-serif; }
.ms-choose-links a:hover, .ms-choose-links a:focus-visible { background: var(--ms-yellow); }

.ms-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 clamp(20px, 3vw, 32px); position: sticky; top: var(--header-h, 0px); z-index: 3; background: var(--ms-cream); padding: 10px 0; }
.ms-chip { font: 500 14px/1 Inter, system-ui, sans-serif; padding: 11px 16px; border: 1px solid var(--ms-line); border-radius: 999px; background: #fff; color: var(--ms-ink); cursor: pointer; }
.ms-chip:hover { border-color: var(--ms-green); }
.ms-chip.on { background: var(--ms-green); border-color: var(--ms-green); color: #fff; }
.ms-chip:focus-visible, .ms-pick:focus-visible, .ms-kitbar-go:focus-visible, .ms-prov-open:focus-visible, .ms-cert-btn:focus-visible { outline: 2px solid var(--ms-cobalt); outline-offset: 2px; }

.ms-group { padding: clamp(18px, 3vw, 28px) 0 clamp(28px, 4vw, 48px); border-top: 2px solid var(--ms-ink); }
.ms-group[hidden], .ms-card[hidden] { display: none !important; }
.ms-group-head { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(20px, 4vw, 56px); margin-bottom: clamp(20px, 3vw, 32px); }
.ms-group-head .section-title { font-size: clamp(30px, 3.6vw, 48px); margin: 8px 0 12px; }
.ms-lede { font-size: 16px; line-height: 1.55; color: #2a2a2a; margin: 0; max-width: 560px; }
.ms-care { background: #fff; border-left: 3px solid var(--ms-green); padding: 18px 20px; align-self: start; }
.ms-care-k { font: 600 12px/1 Inter, system-ui, sans-serif; letter-spacing: .1em; text-transform: uppercase; color: var(--ms-green); margin: 0 0 10px; }
.ms-care ul { margin: 0; padding: 0 0 0 18px; }
.ms-care li { font-size: 14.5px; line-height: 1.5; color: #222; margin: 0 0 6px; }
.ms-care-links { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 12px 0 0; }
.ms-care-links a, .ms-on a { color: var(--ms-cobalt); }

.ms-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: clamp(14px, 2vw, 24px); }
.ms-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--ms-line); }
.ms-spec { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; background: var(--ms-sw); }
.ms-spec img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; mix-blend-mode: overlay; transform: scale(1.35); }
.ms-card-b { padding: 16px 16px 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.ms-kind { margin: 0; font: 600 12px/1.2 Inter, system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; color: var(--ms-green); }
.ms-card h3 { margin: 0; font-size: 21px; font-weight: 500; letter-spacing: -0.02em; text-transform: none; color: var(--ms-ink); }
.ms-note { margin: 0; font-size: 14px; line-height: 1.5; color: #333; }
.ms-on { margin-top: auto; border-top: 1px solid var(--ms-line); padding-top: 10px; }
.ms-on summary { cursor: pointer; font: 500 14px/1.3 Inter, system-ui, sans-serif; color: var(--ms-ink); }
.ms-pieces { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 6px; max-height: 260px; overflow: auto; }
.ms-pieces a { display: flex; align-items: center; gap: 10px; font-size: 14px; text-decoration: none; }
.ms-pieces a:hover { text-decoration: underline; }
.ms-thumb { position: relative; flex: none; width: 36px; height: 36px; background: var(--ms-cream); overflow: hidden; }
.ms-thumb .pimg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ms-pick { display: inline-flex; align-items: center; gap: 10px; align-self: flex-start; margin-top: 4px; padding: 10px 14px; border: 1px solid var(--ms-ink); background: #fff; color: var(--ms-ink); font: 500 14px/1 Inter, system-ui, sans-serif; cursor: pointer; }
.ms-pick-box { width: 14px; height: 14px; border: 1.5px solid currentColor; position: relative; }
.ms-pick.on { background: var(--ms-yellow); border-color: var(--ms-yellow); }
.ms-pick.on .ms-pick-box::after { content: ""; position: absolute; left: 3.5px; top: 0; width: 4px; height: 8px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.ms-pick:disabled { opacity: .45; cursor: not-allowed; }
.ms-credit { font-size: 13px; color: #555; margin: 8px 0 0; }

.ms-kitbar { position: fixed; left: 0; right: 0; bottom: 0; margin: 0 !important; z-index: 40; display: flex; align-items: center; justify-content: center; gap: 18px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: var(--ms-ink); color: #fff; }
html:has(.ms-kitbar) { --buybar-h: 64px; }
.ms-kitbar-t { margin: 0; font-size: 15px; line-height: 1.35; }
.ms-kitbar-t b { color: var(--ms-yellow); font-weight: 600; }
.ms-kitbar-go { flex: none; padding: 12px 18px; border: 0; background: var(--ms-yellow); color: var(--ms-ink); font: 600 14px/1 Inter, system-ui, sans-serif; cursor: pointer; }
.ms-kitbar-go:disabled { background: rgba(255, 255, 255, .25); color: rgba(255, 255, 255, .75); cursor: not-allowed; }

@media (max-width: 760px) {
  .ms-choose-cols, .ms-group-head { grid-template-columns: 1fr; }
  .ms-chips { flex-wrap: nowrap; overflow-x: auto; margin-left: -16px; margin-right: -16px; padding-left: 16px; padding-right: 16px; scrollbar-width: none; }
  .ms-chips::-webkit-scrollbar { display: none; }
  .ms-chip { flex: none; }
  .ms-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .ms-card-b { padding: 12px; }
  .ms-card h3 { font-size: 17px; }
  .ms-note { display: none; }
  .ms-pick { padding: 9px 10px; font-size: 13px; align-self: stretch; justify-content: center; }
  .ms-kitbar { justify-content: space-between; gap: 10px; }
  .ms-kitbar-t { font-size: 13px; }
  .ms-kitbar-n { display: none; }
}

/* ---------------- certificate of provenance on the order ---------------- */
.ms-prov { padding-bottom: 0; }
.ms-prov-card { display: grid; grid-template-columns: 220px minmax(0, 1fr); background: #fff; border: 1px solid var(--ms-line); }
.ms-prov-mark { background: var(--ms-green); display: flex; align-items: center; justify-content: center; padding: 28px; }
.ms-prov-mark img { width: 140px; height: auto; }
.ms-prov-b { padding: clamp(20px, 3vw, 36px); }
.ms-prov-b .section-title { font-size: clamp(22px, 2.4vw, 32px); margin: 8px 0 10px; text-transform: none; }
.ms-prov-lede { font-size: 15px; line-height: 1.55; color: #2a2a2a; margin: 0 0 18px; max-width: 640px; }
.ms-prov-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.ms-prov-list li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 14px; background: var(--ms-cream); padding: 12px 14px; border: 1px solid var(--ms-line); }
.ms-prov-no { font: 600 13px/1 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: .04em; color: var(--ms-green); white-space: nowrap; }
.ms-prov-what { font-size: 14px; color: #333; line-height: 1.4; }
.ms-prov-what b { display: block; color: var(--ms-ink); font-weight: 600; }
.ms-prov-open { padding: 11px 14px; border: 0; background: var(--ms-ink); color: #fff; font: 500 14px/1 Inter, system-ui, sans-serif; cursor: pointer; white-space: nowrap; }
.ms-prov-open:hover { background: var(--ms-green); }
@media (max-width: 760px) {
  .ms-prov-card { grid-template-columns: 1fr; }
  .ms-prov-mark { padding: 18px; }
  .ms-prov-mark img { width: 104px; }
  .ms-prov-list li { grid-template-columns: 1fr; gap: 8px; }
  .ms-prov-open { justify-self: start; }
}

/* the certificate itself: a dialog on screen, the only thing on the page in print */
.ms-cert { position: fixed; inset: 0; z-index: 1000; overflow: auto; background: rgba(18, 18, 18, .6); padding: 24px 16px; }
.ms-cert-bar { position: sticky; top: 0; z-index: 1; display: flex; justify-content: center; gap: 10px; margin: 0 auto 14px; max-width: 760px; }
.ms-cert-btn { padding: 12px 18px; border: 0; background: var(--ms-yellow); color: var(--ms-ink); font: 600 14px/1 Inter, system-ui, sans-serif; cursor: pointer; }
.ms-cert-btn.ghost { background: #fff; }
.ms-cert-page { max-width: 760px; margin: 0 auto; background: var(--ms-cream); color: var(--ms-ink); padding: 0 0 clamp(24px, 4vw, 40px); border: 10px solid var(--ms-green); font: 400 14px/1.5 Inter, system-ui, sans-serif; }
.ms-cert-top { background: var(--ms-green); color: #fff; display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 26px 20px 20px; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.ms-cert-top img { width: 132px; height: auto; }
.ms-cert-top p { margin: 0; font: 600 13px/1 Inter, system-ui, sans-serif; letter-spacing: .18em; text-transform: uppercase; color: var(--ms-yellow); }
.ms-cert-page h1 { text-align: center; font-size: clamp(30px, 5vw, 46px); font-weight: 500; letter-spacing: -0.03em; margin: clamp(22px, 4vw, 34px) 20px 4px; text-transform: none; }
.ms-cert-sub { text-align: center; margin: 0 20px clamp(18px, 3vw, 28px); color: var(--ms-green); font-size: 15px; }
.ms-cert-dl { margin: 0 clamp(20px, 5vw, 56px); display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--ms-line); }
.ms-cert-dl div { padding: 11px 12px 11px 0; border-bottom: 1px solid var(--ms-line); }
.ms-cert-dl dt { font: 600 11px/1.2 Inter, system-ui, sans-serif; letter-spacing: .1em; text-transform: uppercase; color: #555; }
.ms-cert-dl dd { margin: 4px 0 0; font-size: 15px; color: var(--ms-ink); overflow-wrap: anywhere; }
.ms-cert-dl div:first-child dd { font: 600 17px/1.2 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; color: var(--ms-green); letter-spacing: .04em; }
.ms-cert-note { margin: 20px clamp(20px, 5vw, 56px) 0; font-size: 13px; line-height: 1.55; color: #333; }
.ms-cert-page footer { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 22px clamp(20px, 5vw, 56px) 0; padding-top: 10px; border-top: 1px solid var(--ms-line); font-size: 11px; color: #555; }
html.ms-cert-open, html.ms-cert-open body { overflow: hidden; }
@media (max-width: 560px) { .ms-cert-dl { grid-template-columns: 1fr; } .ms-cert { padding: 12px 8px; } }
@media print {
  html.ms-cert-open body > *:not(.ms-cert) { display: none !important; }
  html.ms-cert-open .ms-cert { position: static; background: none; padding: 0; overflow: visible; }
  html.ms-cert-open .ms-cert-bar { display: none; }
  html.ms-cert-open .ms-cert-page { max-width: none; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  html.ms-cert-open, html.ms-cert-open body { overflow: visible; background: #ffffff; }
  .ms-kitbar { display: none; }
}
