/* =========================================================
   3DBRUSH product detail page
   Works with shared /includes/site_header.php and 3dbrush_main.css
   ========================================================= */
body.mk-product-detail-page {
  background:
    radial-gradient(circle at 8% 0%, rgba(240,120,18,.08), transparent 26%),
    linear-gradient(180deg, #f5f7fb 0%, #eef2f7 100%) !important;
}

.mk-stars-left,
.mk-stars-right {
  position: absolute;
  top: 88px;
  z-index: 0;
  pointer-events: none;
  opacity: .65;
}
.mk-stars-left { left: 0; }
.mk-stars-right { right: 0; transform: scale(-1, 1); }

.mk-product-page {
  position: relative;
  z-index: 1;
  padding: 28px 0 40px;
}

.mk-product-shell {
  width: min(1400px, calc(100% - 64px));
  margin: 0 auto;
}

.mk-product-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 18px;
  color: #667085;
  font-size: 13px;
  font-weight: 500;
}
.mk-product-breadcrumb a {
  color: #667085 !important;
  transition: color .18s ease;
}
.mk-product-breadcrumb a:hover { color: var(--mk-orange) !important; }
.mk-product-breadcrumb b {
  color: #111827;
  font-weight: 600;
  max-width: 520px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mk-product-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 24px;
  align-items: start;
}

.mk-product-main {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.mk-product-gallery-card,
.mk-product-description-card,
.mk-buy-card,
.mk-side-card,
.mk-related-section {
  background: #fff;
  border: 1px solid rgba(15,23,42,.07);
  border-radius: 24px;
  box-shadow: 0 18px 44px rgba(15,23,42,.09);
  overflow: hidden;
}

.mk-product-gallery-card {
  padding: 16px;
}

.mk-product-gallery-main {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 520px;
  border-radius: 20px;
  overflow: hidden;
  background: radial-gradient(circle at 50% 38%, #222b35 0%, #121821 54%, #05070b 100%);
}
.mk-product-gallery-main img {
  display: block;
  width: 100%;
  max-height: 600px;
  object-fit: contain;
}
.mk-no-image {
  color: rgba(255,255,255,.65);
  font-size: 16px;
  font-weight: 600;
}
.mk-gallery-open {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 13px;
  background: rgba(17,24,39,.72);
  color: #fff;
  font-size: 25px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(10px);
  transition: background .18s ease, color .18s ease, transform .18s ease;
}
.mk-gallery-open:hover {
  color: var(--mk-orange-2);
  background: rgba(17,24,39,.88);
  transform: translateY(-1px);
}

.mk-product-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.mk-thumb {
  height: 82px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 14px;
  background: #0b0f14;
  overflow: hidden;
  cursor: pointer;
  transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.mk-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.mk-thumb:hover,
.mk-thumb.is-active {
  border-color: var(--mk-orange);
  box-shadow: 0 10px 22px rgba(240,120,18,.18);
  transform: translateY(-1px);
}

.mk-product-description-card {
  padding: 0;
}
.mk-product-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 14px 16px 0;
  border-bottom: 1px solid rgba(15,23,42,.07);
}
.mk-product-tabs button {
  position: relative;
  padding: 13px 16px 15px;
  border: 0;
  background: transparent;
  color: #667085;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}
.mk-product-tabs button.is-active {
  color: #111827;
}
.mk-product-tabs button.is-active::after {
  content: "";
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: -1px;
  height: 2px;
  border-radius: 999px;
  background: var(--mk-orange);
}
.mk-tab-panel {
  display: none;
  padding: 22px 24px 26px;
}
.mk-tab-panel.is-active { display: block; }
.mk-product-description {
  color: #344054;
  font-size: 15px;
  line-height: 1.75;
  white-space: normal;
}
.mk-free-note {
  display: inline-flex;
  margin: 0 0 14px;
  padding: 8px 12px;
  border-radius: 999px;
  background: #fff7ed;
  color: var(--mk-orange);
  font-weight: 700;
}
.mk-tags-list {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid rgba(15,23,42,.07);
}
.mk-tags-list > i { color: #667085; font-size: 19px; }
.mk-tags-list a {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: #f2f4f7;
  color: #475467 !important;
  font-size: 12px;
  font-weight: 600;
}
.mk-tags-list a:hover {
  background: #fff7ed;
  color: var(--mk-orange) !important;
}

.mk-comments-box { display: grid; gap: 16px; }
.mk-comment-form {
  display: grid;
  gap: 12px;
}
.mk-comment-form textarea {
  min-height: 110px;
  resize: vertical;
  border: 1px solid #dbe0e7;
  border-radius: 16px;
  padding: 14px 15px;
  color: #111827;
  font-size: 15px;
  font-family: inherit;
  outline: none;
}
.mk-comment-form textarea:focus {
  border-color: var(--mk-orange);
  box-shadow: 0 0 0 4px rgba(240,120,18,.12);
}
.mk-btn-primary,
.mk-buy-button {
  border: 0;
  border-radius: 15px;
  background: linear-gradient(180deg, #ff8a18, #f07812);
  color: #fff !important;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 14px 28px rgba(240,120,18,.24);
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}
.mk-btn-primary {
  justify-self: start;
  padding: 12px 18px;
}
.mk-btn-primary:hover,
.mk-buy-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(240,120,18,.30);
  filter: saturate(1.04);
}
.mk-login-notice {
  border: 1px solid rgba(240,120,18,.18);
  border-radius: 16px;
  background: #fff7ed;
  color: #7c2d12;
  padding: 14px 16px;
  font-size: 14px;
  font-weight: 600;
}
.mk-login-notice a { color: var(--mk-orange) !important; }
.mk-comments-list { overflow: hidden; }

.mk-product-sidebar {
  display: grid;
  gap: 16px;
  position: sticky;
  top: 92px;
}
.mk-buy-card {
  padding: 24px;
}
.mk-product-title {
  margin: 0;
  color: #101620;
  font-size: 24px;
  font-weight: 650;
  line-height: 1.25;
  letter-spacing: -.025em;
}
.mk-product-meta-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
  color: #667085;
  font-size: 13px;
  font-weight: 600;
}
.mk-product-meta-line span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.mk-product-meta-line i { font-size: 18px; color: #475467; }
.mk-product-price-box {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 22px;
}
.mk-product-price {
  color: var(--mk-orange);
  font-size: 34px;
  font-weight: 750;
  line-height: 1;
  letter-spacing: -.035em;
}
.mk-product-price--free {
  color: #12b76a;
}
.mk-old-price {
  color: #98a2b3;
  font-size: 16px;
  font-weight: 600;
  text-decoration: line-through;
}
.mk-discount {
  padding: 5px 8px;
  border-radius: 999px;
  background: #fef3f2;
  color: #d92d20;
  font-size: 12px;
  font-weight: 800;
}
.mk-product-license {
  margin-top: 18px;
  padding: 13px 14px;
  border-radius: 15px;
  background: #f8fafc;
  color: #667085;
  font-size: 13px;
  line-height: 1.55;
}
.mk-buy-form { margin-top: 18px; }
.mk-buy-button {
  width: 100%;
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.mk-buy-button i { font-size: 22px; }
.mk-product-actions-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}
.mk-product-actions-row a,
.mk-product-actions-row button {
  width: 100%;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid rgba(15,23,42,.11);
  border-radius: 13px;
  background: #fff;
  color: #344054 !important;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.mk-product-actions-row button.is-liked,
.mk-product-actions-row a:hover,
.mk-product-actions-row button:hover {
  border-color: rgba(240,120,18,.32);
  background: #fff7ed;
  color: var(--mk-orange) !important;
}

.mk-side-card {
  padding: 20px;
}
.mk-side-card h3 {
  margin: 0 0 12px;
  color: #101620;
  font-size: 17px;
  font-weight: 650;
}
.mk-author-top {
  display: flex;
  align-items: center;
  gap: 13px;
}
.mk-author-top img {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  object-fit: cover;
  background: #f2f4f7;
}
.mk-author-top h3 {
  margin: 0;
  font-size: 16px;
}
.mk-author-top p {
  margin: 2px 0 0;
  color: #667085;
  font-size: 13px;
  font-weight: 600;
}
.mk-author-stats {
  display: grid;
  gap: 8px;
  margin-top: 15px;
  padding-top: 14px;
  border-top: 1px solid rgba(15,23,42,.07);
}
.mk-author-stats span {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #475467;
  font-size: 13px;
  font-weight: 600;
}
.mk-author-stats i { color: var(--mk-orange); font-size: 18px; }
.mk-format-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.mk-format-list span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 11px;
  border-radius: 999px;
  background: #f2f4f7;
  color: #344054;
  font-size: 13px;
  font-weight: 700;
}
.mk-benefits-card ul {
  display: grid;
  gap: 11px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.mk-benefits-card li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  color: #475467;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.45;
}
.mk-benefits-card i { color: var(--mk-orange); font-size: 18px; }

.mk-block-title {
  margin: 0 0 16px;
  color: #101620;
  font-size: 20px;
  font-weight: 650;
}
.mk-video-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 18px;
  background: #0b0f14;
}
.mk-video-wrap iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.mk-related-section {
  margin-top: 24px;
  padding: 22px;
}
.mk-related-section h2 {
  margin: 0 0 16px;
  color: #101620;
  font-size: 22px;
  font-weight: 650;
  letter-spacing: -.02em;
}
.mk-related-grid {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 10px !important;
}
.mk-related-card {
  min-height: 0;
  box-shadow: 0 12px 30px rgba(15,23,42,.09);
}
.mk-related-card .mk-card-image { height: 190px; }

.mk-lightbox {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 32px;
  background: rgba(3,7,12,.88);
  backdrop-filter: blur(8px);
}
.mk-lightbox.is-open { display: flex; }
.mk-lightbox img {
  max-width: min(1180px, 94vw);
  max-height: 90vh;
  object-fit: contain;
  border-radius: 18px;
  box-shadow: 0 28px 80px rgba(0,0,0,.45);
}
.mk-lightbox-close {
  position: fixed;
  top: 18px;
  right: 18px;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 15px;
  background: rgba(17,24,39,.78);
  color: #fff;
  font-size: 28px;
  cursor: pointer;
}
.mk-lightbox-close:hover { color: var(--mk-orange-2); }

@media (max-width: 1180px) {
  .mk-product-shell { width: min(100% - 34px, 1400px); }
  .mk-product-layout {
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 18px;
  }
  .mk-product-gallery-main { min-height: 460px; }
}

@media (max-width: 991.98px) {
  .mk-product-page { padding-top: 20px; }
  .mk-product-layout { grid-template-columns: 1fr; }
  .mk-product-sidebar { position: static; grid-row: 1; }
  .mk-product-gallery-main { min-height: 420px; }
  .mk-related-grid { grid-template-columns: repeat(2, minmax(0,1fr)) !important; }
}

@media (max-width: 575.98px) {
  .mk-product-shell { width: min(100% - 20px, 1400px); }
  .mk-product-breadcrumb { margin-top: 4px; }
  .mk-product-breadcrumb b { max-width: 240px; }
  .mk-product-gallery-card { padding: 10px; border-radius: 18px; }
  .mk-product-gallery-main { min-height: 320px; border-radius: 15px; }
  .mk-product-thumbs { grid-template-columns: repeat(4, minmax(0,1fr)); gap: 8px; }
  .mk-thumb { height: 64px; border-radius: 10px; }
  .mk-buy-card,
  .mk-side-card,
  .mk-tab-panel { padding: 18px; }
  .mk-product-title { font-size: 20px; }
  .mk-product-price { font-size: 29px; }
  .mk-product-actions-row { grid-template-columns: 1fr; }
  .mk-product-tabs { overflow-x: auto; }
  .mk-product-tabs button { white-space: nowrap; }
  .mk-related-grid { grid-template-columns: 1fr !important; }
  .mk-lightbox { padding: 16px; }
}
