

/* =========================================================
   LAPSERO - Product Detail Modal (PDP) & Modal Styles
   ========================================================= */

/* Backdrop Overlay */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(10, 22, 38, 0.75);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  display: none;
  place-items: center;
  z-index: 9999;
  padding: 20px;
  overflow-y: auto;
}
.modal.open {
  display: grid;
}

/* Modal Box Container */
.modal-box {
  background: #ffffff !important;
  color: #14202e !important;
  border-radius: 20px;
  width: 100%;
  max-width: 1080px;
  max-height: 90vh;
  min-width: 0;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.45);
  border: 1px solid #e2e8f0;
  margin: auto;
  animation: pdpModalFade 0.25s ease-out;
}

@keyframes pdpModalFade {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Close Button */
.pdp-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  color: #475569;
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 100;
  transition: all 0.2s ease;
}
.pdp-close:hover {
  background: #e2e8f0;
  color: #0f172a;
  transform: scale(1.08);
}

/* Breadcrumb */
.pdp-crumb {
  font-size: 12.5px;
  color: #64748b;
  font-weight: 600;
  padding: 18px 24px 0;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Main Grid Layout */
.pdp-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 24px;
  padding: 16px 24px 28px;
  background: #ffffff;
}

/* let grid children shrink so the modal never overflows on small screens */
.pdp-grid > * {
  min-width: 0;
}

/* Left Gallery Column */
.pdp-gal {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 16px;
  display: flex;
  flex-direction: column;
}

.pdp-grade {
  display: inline-block;
  background: #0d7a4f;
  color: #ffffff;
  font-size: 11.5px;
  font-weight: 800;
  padding: 5px 12px;
  border-radius: 6px;
  margin-bottom: 12px;
  align-self: flex-start;
  letter-spacing: 0.3px;
}

.pdp-main {
  width: 100% !important;
  height: auto !important;
  aspect-ratio: 16 / 9;
  max-height: 420px;
  object-fit: contain;
  object-position: center;
  border-radius: 12px;
  background: #eef2f7;
  display: block;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.pdp-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.pdp-thumbs img {
  flex: 1 1 70px;
  min-width: 0;
  max-width: 150px;
  height: 78px !important;
  object-fit: contain;
  border-radius: 8px;
  cursor: pointer;
  border: 2px solid #e2e8f0;
  background: #ffffff;
  transition: all 0.2s ease;
}

.pdp-thumbs img:hover,
.pdp-thumbs img.sel {
  border-color: #0d7a4f;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(13, 122, 79, 0.15);
}

.pdp-trust3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
  text-align: center;
}

.pdp-trust3 div {
  font-size: 11px;
  font-weight: 600;
  color: #334155;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px 6px;
  line-height: 1.4;
}

/* Right Info Column */
.pdp-info {
  background: #ffffff;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pdp-meta {
  font-size: 11.5px;
  font-weight: 800;
  color: #e67e22;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

.pdp-info h2 {
  font-size: 22px;
  font-weight: 800;
  color: #0e1b2c;
  line-height: 1.35;
  margin: 0;
}

.pdp-info .rating {
  font-size: 13.5px;
  color: #b45309;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Price Box */
.pdp-price {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 12px 16px;
  margin: 4px 0;
  flex-wrap: wrap;
}

.pdp-price b {
  font-size: 28px;
  font-weight: 800;
  color: #0e1b2c;
}

.pdp-price s {
  color: #94a3b8;
  font-size: 15px;
  font-weight: 600;
}

.pdp-save {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
  font-size: 12px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 20px;
}

/* Quantity Box */
.pdp-qty {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 13.5px;
  font-weight: 700;
  color: #334155;
  margin: 4px 0;
}

.pdp-qty .qbox {
  display: flex;
  align-items: center;
  border: 1.5px solid #cbd5e1;
  border-radius: 10px;
  overflow: hidden;
  background: #ffffff;
}

.pdp-qty button {
  width: 34px;
  height: 34px;
  border: 0;
  background: #f1f5f9;
  color: #0f172a;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.15s;
}

.pdp-qty button:hover {
  background: #e2e8f0;
}

.pdp-qty span {
  min-width: 38px;
  text-align: center;
  font-size: 15px;
  font-weight: 800;
  color: #0e1b2c;
}

/* Action Buttons */
.pdp-btns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 8px 0 14px;
}

.pdp-add {
  background: #0d7a4f;
  color: #ffffff;
  border: 0;
  border-radius: 12px;
  padding: 13px;
  font-weight: 800;
  font-size: 14.5px;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(13, 122, 79, 0.25);
}

.pdp-add:hover {
  background: #0b6541;
  transform: translateY(-1px);
}

.pdp-buy {
  background: #0e1b2c;
  color: #ffffff;
  border: 0;
  border-radius: 12px;
  padding: 13px;
  font-weight: 800;
  font-size: 14.5px;
  cursor: pointer;
  transition: all 0.2s;
}

.pdp-buy:hover {
  background: #1a2f4c;
  transform: translateY(-1px);
}

/* Specifications Table */
.pdp-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  font-size: 13px;
  margin-top: 4px;
}

.pdp-table tr {
  border-bottom: 1px solid #eef2f7;
}

.pdp-table tr:last-child {
  border-bottom: 0;
}

.pdp-table td {
  padding: 9px 12px;
  vertical-align: middle;
}

.pdp-table td:first-child {
  width: 34%;
  color: #64748b;
  font-weight: 600;
  background: #f8fafc;
  border-right: 1px solid #eef2f7;
}

.pdp-table td:last-child {
  color: #0f172a;
  font-weight: 600;
  background: #ffffff;
}

/* Policy Modal Support */
.policy-box {
  max-width: 680px;
  padding: 24px;
}
.policy-head h2 { font-size: 22px; color: #0e1b2c; margin-bottom: 4px; }
.policy-head small { color: #64748b; font-size: 13px; }
.policy-body { margin-top: 16px; font-size: 14px; line-height: 1.6; color: #334155; }
.policy-body h3 { font-size: 15px; color: #0e1b2c; margin: 14px 0 6px; }
.policy-body ul { padding-left: 20px; margin: 8px 0; }

/* Responsive Adjustments */
@media (max-width: 840px) {
  .modal { padding: 12px; }
  .pdp-grid { grid-template-columns: 1fr; gap: 18px; padding: 14px 16px 20px; }
  .pdp-main { max-height: 300px; }
  .pdp-crumb { padding: 14px 16px 0; }
  .pdp-info h2 { font-size: 19px; }
}
