:root {
  --white:    #FFFFFF;
  --snow:     #F8FAFC;
  --snow2:    #EEF4F8;
  --snow3:    #E4EEF5;
  --steel:    #5A8AA7;
  --steel-lt: #7AAEC8;
  --royal:    #2843A7;
  --royal-lt: #3A58C4;
  --ink:      #0E1A2B;
  --slate:    #3D5166;
  --muted:    #7A96AA;
  --muted2:   #B0C4D0;
  --border:   rgba(90,138,167,.15);
  --border2:  rgba(90,138,167,.09);
  --sh:       0 2px 16px rgba(40,67,167,.07), 0 1px 3px rgba(14,26,43,.04);
  --sh-md:    0 8px 32px rgba(40,67,167,.10), 0 2px 8px rgba(14,26,43,.06);
  --sh-lg:    0 20px 60px rgba(40,67,167,.14), 0 4px 16px rgba(14,26,43,.08);
  --ff-d:     'Libre Baskerville', Georgia, serif;
  --ff-b:     'Plus Jakarta Sans', sans-serif;
  --ease:     cubic-bezier(.25,.46,.45,.94);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--snow);
  color: var(--ink);
  font-family: var(--ff-b);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, h4, h5, h6 { font-family: var(--ff-d); }
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--snow); }
::-webkit-scrollbar-thumb { background: var(--steel); border-radius: 2px; }

/* ── Nav overrides ── */
.nav-desktop {
  position: static !important;
  margin-top: 0 !important;
}
.nav-desktop-links ul li a {
  color: var(--ink) !important;
  font-family: var(--ff-b) !important;
}
.nav-tablet {
  position: static !important;
  margin-top: 0 !important;
}
.nav-tablet-links ul li a {
  color: var(--ink) !important;
  font-family: var(--ff-b) !important;
}
.nav-mobile {
  position: static !important;
  margin-top: 0 !important;
}

/* ── Bootstrap container cap ── */
.container, .container-lg, .container-md, .container-sm {
  max-width: 1300px !important;
}

/* ── Back link ── */
.back-link {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 5px;
  font-family: var(--ff-b);
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: .06em;
  text-transform: uppercase;
  margin-bottom: 14px;
  transition: color .2s;
}
.back-link:hover { color: var(--royal); text-decoration: none; }

/* ── Page layout ── */
.main {
  width: 90%;
  max-width: 1300px;
  margin: 32px auto 0;
  display: flex;
  flex-direction: row;
  gap: 28px;
  align-items: flex-start;
  padding: 0;
}

/* ── Left panel — image + title ── */
.containers {
  flex: 1;
  min-width: 0;
  background: var(--white);
  border: 1px solid var(--border2);
  border-radius: 14px;
  padding: 24px;
  box-shadow: var(--sh);
  position: relative;
  overflow: hidden;
  transition: box-shadow .35s var(--ease);
}
.containers:hover { box-shadow: var(--sh-md); }
.containers::before { display: none; }

/* Title + price header */
.sideheader {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}
.sideheader h1 {
  font-family: var(--ff-d);
  font-size: clamp(16px, 2.2vw, 26px);
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -.02em;
  line-height: 1.2;
  word-break: break-word;
  flex: 1;
  min-width: 0;
}
.sideheader .price {
  font-family: var(--ff-d);
  font-size: 18px;
  font-weight: 700;
  color: var(--royal);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Price label pills */
.call-label, .obo-label, .sp-label, .starting-bid-label {
  background: rgba(40,67,167,.08);
  color: var(--royal);
  border: 1px solid rgba(40,67,167,.15);
  border-radius: 100px;
  padding: 3px 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
  font-family: var(--ff-b);
  display: inline-block;
}

/* School / type badge */
.school-badge {
  background: rgba(40,67,167,.08);
  color: var(--royal);
  border: 1px solid rgba(40,67,167,.15);
  border-radius: 100px;
  padding: 3px 14px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
  display: inline-block;
}

/* ── Image section ── */
.image-section { position: relative; margin-top: 0; }
.main-image-wrapper {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
}
#main-image {
  width: 100%;
  height: 420px;
  object-fit: contain;
  display: block;
  border-radius: 10px;
  background: var(--snow);
}
.arrows {
  position: absolute;
  top: 50%;
  left: 0; right: 0;
  display: none;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px;
  transform: translateY(-50%);
}
.arrow-left, .arrow-right {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  background: rgba(14,26,43,.58);
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  border-radius: 50%;
  backdrop-filter: blur(4px);
  transition: background .2s;
  flex-shrink: 0;
}
.arrow-left:hover, .arrow-right:hover { background: rgba(14,26,43,.85); }
.image-section:hover .arrows { display: flex; }
.thumbnail-row {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  overflow-x: auto;
  padding-bottom: 4px;
  justify-content: center;
}
.thumbnail-row img {
  width: 80px;
  height: 60px;
  object-fit: cover;
  border-radius: 6px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color .2s, transform .2s;
}
.thumbnail-row img:hover {
  border-color: var(--royal);
  transform: scale(1.05);
}

/* ── Right panel — contact/details card ── */
.sidebar {
  flex: 0 0 360px;
  width: 360px;
  background: var(--white);
  border: 1px solid var(--border2);
  border-radius: 14px;
  box-shadow: var(--sh-md);
  overflow: hidden;
  position: sticky;
  top: 16px;
  transition: box-shadow .35s var(--ease);
}
.sidebar:hover { box-shadow: var(--sh-lg); }
.sidebar::before {
  content: '';
  display: block;
  height: 3px;
  background: linear-gradient(90deg, var(--royal), var(--steel));
}

/* Seller name block */
.seller-name {
  padding: 16px 20px 4px;
  font-family: var(--ff-b);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: .06em;
  text-transform: uppercase;
}
.seller-name strong {
  display: block;
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  font-family: var(--ff-d);
  margin-top: 3px;
  text-transform: none;
  letter-spacing: 0;
}

/* CTA button links */
.sidebar a.sd-link {
  display: block;
  padding: 0 20px;
  text-decoration: none;
}
.sidebar a.sd-link:first-of-type { padding-top: 20px; }
.sidebar a.sd-link:last-of-type  { padding-bottom: 18px; }

/* Primary button */
.btn-cta-primary {
  width: 100%;
  padding: 13px 16px;
  background: var(--royal);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: var(--ff-b);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  box-shadow: 0 4px 18px rgba(40,67,167,.32);
  transition: background .25s, transform .2s, box-shadow .25s;
  margin-bottom: 8px;
  letter-spacing: .01em;
}
.btn-cta-primary:hover {
  background: var(--royal-lt);
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(40,67,167,.42);
}

/* Secondary button */
.btn-cta-secondary {
  width: 100%;
  padding: 11px 16px;
  background: var(--snow2);
  color: var(--royal);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: var(--ff-b);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
  letter-spacing: .06em;
  transition: background .2s, border-color .2s, color .2s;
  margin-bottom: 8px;
}
.btn-cta-secondary:hover {
  background: var(--royal);
  color: #fff;
  border-color: var(--royal);
}

/* Share strip */
.sd-divider { height: 1px; background: var(--border2); margin: -2px 0 12px; }
.sd-share { padding: 0 20px 16px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sd-share-label { font-size: 10px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--muted2); margin-right: 2px; }
.share-btn {
  width: 30px; height: 30px; border-radius: 7px;
  border: 1px solid var(--border2); background: var(--white);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; color: var(--muted); cursor: pointer; text-decoration: none;
  text-transform: none; font-weight: 400;
  transition: background .2s, color .2s, border-color .2s;
}
.share-btn:hover, a.share-btn:hover { background: var(--royal); color: #fff !important; border-color: var(--royal); text-decoration: none; }
.share-btn.copied, a.share-btn.copied { background: #16a34a; color: #fff !important; border-color: #16a34a; }

/* Details table */
.sidebar .details-table {
  width: 100%;
  border-collapse: collapse;
}
.sidebar .details-table tr {
  border-bottom: 1px solid var(--border2);
}
.sidebar .details-table tr:last-child { border-bottom: none; }
.sidebar .details-table th,
.sidebar .details-table td {
  padding: 13px 20px;
  text-align: left;
  border-bottom: none;
  font-family: var(--ff-b);
}
.sidebar .details-table th {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted2);
  width: 42%;
}
.sidebar .details-table td {
  font-size: 11px;
  font-weight: 500;
  color: var(--ink);
  word-break: break-word;
}

/* Doc toggle button */
.doc-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 11px;
  background: var(--royal);
  color: var(--white) !important;
  border: 1px solid rgba(40,67,167,.18);
  border-radius: 6px;
  font-family: var(--ff-b);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .05em;
  text-decoration: none;
  cursor: pointer;
  transition: background .2s, border-color .2s, color .2s;
}
.doc-link:hover {
  background: var(--royal-lt);
  color: #fff !important;
  border-color: var(--royal-lt);
  text-decoration: none;
}

/* Individual doc item links inside the expanded list */
.doc-item-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  background: var(--snow2);
  color: var(--royal) !important;
  border: 1px solid var(--border);
  border-radius: 5px;
  font-size: 11px;
  font-weight: 600;
  text-decoration: none;
  margin-bottom: 4px;
  transition: background .2s, color .2s, border-color .2s;
}
.doc-item-link:hover {
  background: var(--royal);
  color: #fff !important;
  border-color: var(--royal);
  text-decoration: none;
}
.doc-unavailable { color: var(--muted); font-size: 12px; font-style: italic; }

/* Doc list expandable row */
.doc-list-row { border-bottom: none !important; }
.doc-list-row td {
  padding: 0 !important;
  border-bottom: none !important;
}
.doc-list-inner {
  overflow: hidden;
  max-height: 0;
  padding: 0 20px;
  transition: max-height .3s ease, padding .3s ease, border-color .3s ease;
  border-top: 1px solid transparent;
}
.doc-list-row.open .doc-list-inner {
  max-height: 300px;
  padding: 10px 20px 14px;
  border-top-color: var(--border2);
}

/* ── Popup ── */
.popup-container {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(14,26,43,.5);
  backdrop-filter: blur(4px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}
.popup-content {
  background: var(--white);
  padding: 28px;
  width: 70%;
  max-width: 800px;
  border-radius: 14px;
  position: relative;
  box-shadow: var(--sh-lg);
}
.close-btn {
  position: absolute;
  top: 14px; right: 18px;
  font-size: 20px;
  cursor: pointer;
  color: var(--muted);
  transition: color .2s;
}
.close-btn:hover { color: var(--ink); }

/* ── Misc ── */
#document-list { display: none; }

/* ── Bottom cards wrapper ── */
.desc-wrapper {
  width: 90%;
  max-width: 1300px;
  margin: 28px auto 56px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Card base (aircraft/engine/parts detail pages) */
.card-section {
  background: var(--white);
  border: 1px solid var(--border2);
  border-radius: 14px;
  padding: 28px 32px;
  box-shadow: var(--sh);
  transition: box-shadow .35s var(--ease);
}
.card-section:hover { box-shadow: var(--sh-md); }
.card-section h2 {
  font-family: var(--ff-d);
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -.01em;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border2);
}
.card-section p {
  font-size: 10px;
  font-weight: 500;
  color: var(--slate);
  line-height: 1.85;
  font-family: var(--ff-b);
}

/* Card base (services detail page uses .right-section) */
.right-section {
  background: var(--white);
  border: 1px solid var(--border2);
  border-radius: 14px;
  padding: 28px 32px;
  box-shadow: var(--sh);
  position: relative;
  overflow: hidden;
  transition: box-shadow .35s var(--ease);
}
.right-section:hover { box-shadow: var(--sh-md); }
.right-section::before { display: none; }
.right-section h2 {
  font-family: var(--ff-d);
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -.01em;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border2);
}
.right-section p {
  font-size: 14px;
  color: var(--slate);
  line-height: 1.85;
  font-family: var(--ff-b);
}

/* Specs table inside card */
.specs-table {
  width: 100%;
  border-collapse: collapse;
}
.specs-table tr { border-bottom: 1px solid var(--border2); }
.specs-table tr:last-child { border-bottom: none; }
.specs-table th {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted2);
  padding: 11px 0;
  width: 38%;
  font-family: var(--ff-b);
}
.specs-table td {
  font-size: 11px;
  font-weight: 500;
  color: var(--ink);
  padding: 11px 0;
  font-family: var(--ff-b);
}

/* Side-by-side row for specs + description */
.cards-row {
  display: flex;
  gap: 20px;
  align-items: stretch;
}
.cards-row .card-section { flex: 1; min-width: 0; }

/* Features text */
.features-text {
  font-size: 10px;
  font-weight: 500;
  color: var(--slate);
  line-height: 1.85;
  font-family: var(--ff-b);
}
.features-text em { color: var(--muted); font-style: italic; }

/* ── Responsive ── */
@media (max-width: 1100px) {
  .main { width: 95%; gap: 20px; }
  .desc-wrapper { width: 95%; margin-top: 20px; }
  #main-image { height: 360px; }
}
@media (max-width: 900px) {
  .sidebar { flex: 0 0 280px; width: 280px; }
  #main-image { height: 320px; }
}
@media (max-width: 768px) {
  .main {
    flex-direction: column;
    width: 95%;
    margin: 20px auto 0;
  }
  .containers, .sidebar {
    flex: none;
    width: 100%;
    position: static;
  }
  #main-image { height: 260px; }
  .sideheader { margin-bottom: 10px; }
  .card-section { padding: 18px 20px; }
  .card-section h2 { font-size: 15px; }
  .right-section { padding: 18px 20px; }
  .right-section h2 { font-size: 15px; }
  .desc-wrapper { width: 95%; margin: 20px auto 40px; }
  .cards-row { flex-direction: column; }
}
@media (max-width: 480px) {
  .containers { padding: 14px; }
  .sidebar a.sd-link { padding: 0 14px; }
  .sidebar a.sd-link:first-of-type { padding-top: 14px; }
  .sidebar a.sd-link:last-of-type  { padding-bottom: 12px; }
  .sidebar .details-table th,
  .sidebar .details-table td { padding: 10px 14px; }
  .btn-cta-primary { padding: 11px 14px; font-size: 13px; }
  .btn-cta-secondary { padding: 10px 14px; }
  .sd-divider { margin: 4px 14px 12px; }
  .sd-share { padding: 0 14px 14px; }
  #main-image { height: 220px; }
}
