*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --red: #C0272D;
  --red-lt: #E03035;
  --ink: #0F1117;
  --ink-3: #5A5D6B;
  --rule: #DDE0E8;
  --rule-lt: #EEF0F5;
  --bg: #F7F8FA;
  --white: #FFFFFF;
  --gold: #A07830;
  --nova: #1A2E52;
  --dark: #141820;
  --dark2: #1E2330;
  --dark3: #252A38;
}

html { scroll-behavior: smooth; }

body {
  font-family: "Geist", sans-serif;
  background: var(--white);
  color: var(--ink);
  overflow-x: clip;   /* clip instead of hidden — doesn't break position:sticky */
  line-height: 1.6;
}
html {
  scroll-behavior: smooth;
  overflow-x: clip;  /* ← use clip not hidden — doesn't create scroll container */
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
}

/* Typography utilities */
.lbl {
  font-size: .67rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  font-weight: 500;
}

.rl {
  width: 30px;
  height: 2px;
  background: var(--red);
  display: inline-block;
  flex-shrink: 0;
}

/* Section patterns */
.section-tag {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.section-tag .lbl { color: var(--ink-3); }

.section-h2 {
  font-family: "Instrument Serif", serif;
  font-size: clamp(1.8rem, 2.7vw, 2.55rem);
  line-height: 1.12;
  color: var(--ink);
}
.section-h2 em { font-style: italic; color: var(--red); }

.section-desc {
  font-size: .88rem;
  line-height: 1.8;
  color: var(--ink-3);
  max-width: 520px;
  font-weight: 300;
  margin-top: 14px;
}

/* Button */
.btn-red {
  background: var(--red);
  color: #fff;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  padding: 12px 24px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: none;
  cursor: pointer;
  transition: background .2s;
  white-space: nowrap;
}
.btn-red:hover { background: var(--red-lt); }

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .65s, transform .65s;
}
.reveal.visible {
  opacity: 1;
  transform: none;
}

/* Animations */
@keyframes fu {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fi {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@media(max-width: 1024px) {
  .container { padding: 0 28px; }
}
@media(max-width: 768px) {
  .container { padding: 0 18px; }
}
/* SCROLL TO TOP */
.scroll-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 42px;
  height: 42px;
  background: var(--red);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity .3s, transform .3s, visibility .3s, background .2s;
  z-index: 300;
}
.scroll-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.scroll-top:hover { background: var(--red-lt); }

@media(max-width: 768px) {
  .scroll-top { bottom: 80px; right: 20px; width: 38px; height: 38px; }
}
/* ── SHARED THUMBNAIL TILE ───────────────────────── */
.dp-thumb {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  background: var(--white);
  border: none;
  overflow: hidden;
  transition: box-shadow .2s, transform .2s;
  position: relative;
}
.dp-thumb:hover {
  z-index: 2;
  box-shadow: 0 4px 20px rgba(0,0,0,.1);
  transform: translateY(-2px);
}

/* image area — 65% of tile */
.dp-thumb-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  border-bottom: 1px solid var(--rule-lt);
}
.dp-thumb-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 12px;
  display: block;
  transition: transform .3s;
}
.dp-thumb:hover .dp-thumb-img img { transform: scale(1.06); }

/* broken image */
.dp-thumb-img.no-img { background: var(--bg); }
.dp-thumb-img.no-img img { display: none; }
.dp-thumb-img.no-img::after {
  content: '—';
  font-size: .7rem;
  color: var(--rule);
}

/* name label — always visible */
.dp-thumb-label {
  padding: 8px 10px;
  font-size: .68rem;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.35;
  text-align: center;
  background: var(--white);
  border-top: none;
  transition: color .2s, background .2s;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}
.dp-thumb:hover .dp-thumb-label {
  color: var(--red);
  background: #fdf5f5;
}

/* ── MOBILE — row layout (shared) ────────────────── */
@media(max-width: 640px) {
  .dp-thumb {
    flex-direction: row;
    align-items: center;
    aspect-ratio: unset;
    border-bottom: 1px solid var(--rule-lt);
    transform: none !important;
    box-shadow: none !important;
  }
  .dp-thumb-img {
    width: 68px;
    height: 68px;
    flex-shrink: 0;
    aspect-ratio: unset;
    border-bottom: none;
    border-right: 1px solid var(--rule-lt);
  }
  .dp-thumb-img img { transition: none; }
  .dp-thumb:hover .dp-thumb-img img { transform: none; }
  .dp-thumb-label {
    text-align: left;
    justify-content: flex-start;
    padding: 0 16px;
    font-size: .8rem;
  }
  .dp-thumb:hover .dp-thumb-label {
    color: var(--ink);
    background: var(--white);
  }
  .dp-thumb:active { background: var(--bg); }
}
/* ── RFQ DRAWER ──────────────────────────────────── */
.rfq-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 399;
  backdrop-filter: blur(2px);
}
.rfq-overlay.active { display: block; }

.rfq-drawer {
  position: fixed;
  top: 0; right: -440px;
  width: 400px;
  max-width: 100vw;
  height: 100%;
  background: var(--white);
  z-index: 400;
  display: flex;
  flex-direction: column;
  transition: right .3s cubic-bezier(.4,0,.2,1);
  box-shadow: none;
}
.rfq-drawer.open {
  right: 0;
  box-shadow: -4px 0 40px rgba(0,0,0,.15);
}

.rfq-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 18px;
  border-bottom: 1px solid var(--rule);
  background: var(--dark);
  flex-shrink: 0;
}
.rfq-drawer-title {
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #fff;
}
.rfq-drawer-sub {
  font-size: .68rem;
  color: rgba(255,255,255,.4);
  margin-top: 2px;
}
.rfq-drawer-close {
  background: rgba(255,255,255,.08);
  border: none;
  color: rgba(255,255,255,.7);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .2s, color .2s;
  flex-shrink: 0;
}
.rfq-drawer-close:hover { background: rgba(255,255,255,.15); color: #fff; }

.rfq-drawer-body {
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--rule) transparent;
}

.rfq-drawer-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  gap: 10px;
  padding: 40px 24px;
  text-align: center;
  color: var(--ink-3);
  font-size: .82rem;
  line-height: 1.6;
}

.rfq-drawer-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--rule-lt);
  transition: background .15s;
}
.rfq-drawer-item:hover { background: var(--bg); }

.rfq-item-img {
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  border: 1px solid var(--rule-lt);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.rfq-item-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 6px;
}
.rfq-item-info {
  flex: 1;
  min-width: 0;
}
.rfq-item-title {
  font-size: .78rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
  transition: color .2s;
}
.rfq-item-title:hover { color: var(--red); }
.rfq-item-meta {
  font-size: .67rem;
  color: var(--ink-3);
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rfq-item-remove {
  background: none;
  border: 1px solid var(--rule);
  color: var(--ink-3);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: border-color .2s, color .2s, background .2s;
}
.rfq-item-remove:hover {
  border-color: var(--red);
  color: var(--red);
  background: #fde8e9;
}

.rfq-drawer-foot {
  padding: 16px 20px;
  border-top: 1px solid var(--rule);
  background: var(--white);
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex-shrink: 0;
}
.rfq-drawer-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--red);
  color: #fff;
  text-decoration: none;
  padding: 13px 20px;
  font-family: "Geist", sans-serif;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  transition: background .2s;
}
.rfq-drawer-submit:hover { background: var(--red-lt); }
.rfq-drawer-clear {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-3);
  font-size: .72rem;
  text-decoration: none;
  padding: 6px;
  transition: color .2s;
}
.rfq-drawer-clear:hover { color: var(--red); }

@media(max-width: 480px) {
  .rfq-drawer { width: 100vw; right: -100vw; }
}