/* OdXpert Plugin Products — Frontend styles */

.odx-pp-archive,
.odx-pp-single {
  padding: 120px 0 80px;
  background: #F7F9FC;
  min-height: 60vh;
}

.odx-pp-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
}

/* Archive header */
.odx-pp-archive-header {
  text-align: center;
  margin-bottom: 48px;
  order: 1;
}

.odx-pp-label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #0097b2;
  margin-bottom: 10px;
}

.odx-pp-title {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 800;
  color: #1A1A2E;
  margin: 0 0 12px;
  line-height: 1.25;
}

.odx-pp-sub {
  font-size: 1.05rem;
  color: #5a5a72;
  margin: 0;
}

/* Grid */
.odx-pp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  order: 2;
}

/* Card */
.odx-pp-card {
  background: #fff;
  border-radius: 16px;
  padding: 0 0 24px;
  border: 1px solid #e8eef3;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all 0.3s ease;
  overflow: hidden;
}

.odx-pp-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0, 151, 178, 0.1);
  border-color: #d0e4ec;
}

.odx-pp-card.is-featured {
  border: 1.5px solid #18cb96;
  box-shadow: 0 8px 28px rgba(24, 203, 150, 0.12);
}

.odx-pp-card-thumb {
  position: relative;
  margin: 0;
  border-radius: 0;
  overflow: hidden;
  background: #0a0a0a;
  aspect-ratio: 16 / 9;
}

.odx-pp-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
  display: block;
  transition: transform 0.4s ease;
}

.odx-pp-card:hover .odx-pp-card-thumb img {
  transform: scale(1.02);
}

.odx-pp-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: linear-gradient(135deg, #18cb96, #0097b2);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 20px;
  z-index: 2;
}

/* Phần nội dung card */
.odx-pp-card-body {
  padding: 18px 22px 0;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.odx-pp-tier {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #7a7a90;
  margin-bottom: 6px;
}

/* Tên + Giá cùng hàng (chỉ trang danh sách) */
.odx-pp-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.odx-pp-card-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0;
  line-height: 1.35;
  flex: 1;
  min-width: 0;
}

.odx-pp-card-title a {
  color: #1A1A2E;
  text-decoration: none;
}

.odx-pp-card-title a:hover {
  color: #0097b2;
}

.odx-pp-price {
  font-size: 1.1rem;
  font-weight: 700;
  color: #e53935;
  line-height: 1.35;
  margin-bottom: 12px;
}

.odx-pp-price-lg {
  font-size: 1.35rem;
}

.odx-pp-price-note {
  font-size: 0.78rem;
  font-weight: 500;
  color: #e53935;
  opacity: 0.85;
  margin-left: 1px;
}

/* Chỉ khi nằm cùng hàng với tên (trang danh sách) */
.odx-pp-title-row .odx-pp-price {
  white-space: nowrap;
  flex-shrink: 0;
  text-align: right;
  margin-bottom: 0;
}

.odx-pp-card-desc {
  font-size: 0.875rem;
  color: #5a5a72;
  margin: 0 0 14px;
  line-height: 1.5;
}

.odx-pp-features {
  list-style: none;
  margin: 0 0 18px;
  padding: 0;
  flex: 1;
}

.odx-pp-features li {
  position: relative;
  padding: 6px 0 6px 24px;
  font-size: 0.85rem;
  color: #1A1A2E;
  border-bottom: 1px solid #f0f4f7;
}

.odx-pp-features li:last-child {
  border-bottom: none;
}

.odx-pp-features li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2318cb96' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E") center/contain no-repeat;
}

.odx-pp-card-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: auto;
  padding: 0 22px;
}

/* Buttons */
.odx-pp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  transition: all 0.25s ease;
  cursor: pointer;
  border: none;
}

.odx-pp-btn-primary {
  background: linear-gradient(135deg, #18cb96, #0097b2);
  color: #fff;
}

.odx-pp-btn-primary:hover {
  opacity: 0.92;
  transform: translateY(-1px);
  color: #fff;
}

.odx-pp-btn-outline {
  background: transparent;
  border: 1.5px solid #e8eef3;
  color: #1A1A2E;
}

.odx-pp-btn-outline:hover {
  border-color: #18cb96;
  color: #18cb96;
}

.odx-pp-btn-block {
  width: 100%;
}

/* Pagination — always below product grid (force order + unique classes) */
.odx-pp-pagination {
  order: 3;
  margin-top: 48px;
  text-align: center;
  position: relative;
  clear: both;
  width: 100%;
  z-index: 1;
  display: block;
}

.odx-pp-pagination .page-numbers {
  display: inline-flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
}

.odx-pp-pagination .page-numbers li {
  display: inline-block;
  margin: 0;
  padding: 0;
}

.odx-pp-pagination .page-numbers a,
.odx-pp-pagination .page-numbers span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 14px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid #e8eef3;
  color: #1A1A2E;
  text-decoration: none;
  font-size: 0.9rem;
  line-height: 1;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.odx-pp-pagination .page-numbers a:hover {
  border-color: #18cb96;
  color: #18cb96;
  background: #f0fafb;
}

.odx-pp-pagination .page-numbers .current {
  background: linear-gradient(135deg, #18cb96, #0097b2);
  color: #fff;
  border-color: transparent;
  font-weight: 600;
}

.odx-pp-pagination .page-numbers .dots {
  background: transparent;
  border: none;
  min-width: auto;
  padding: 0 6px;
}

.odx-pp-empty {
  order: 2;
  text-align: center;
  color: #5a5a72;
  padding: 60px 20px;
}

/* ========== SINGLE ========== */
.odx-pp-breadcrumb {
  font-size: 0.9rem;
  color: #5a5a72;
  margin-bottom: 32px;
}

.odx-pp-breadcrumb a {
  color: #0097b2;
  text-decoration: none;
}

.odx-pp-breadcrumb a:hover {
  text-decoration: underline;
}

.odx-pp-breadcrumb span {
  margin: 0 8px;
  color: #a0aec0;
}

.odx-pp-single-grid {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 40px;
  align-items: start;
}

.odx-pp-main-col {
  display: flex;
  flex-direction: column;
  gap: 28px;
  min-width: 0;
}

.odx-pp-thumb {
  border-radius: 16px;
  overflow: hidden;
  background: #fff;
  border: 1px solid #e8eef3;
}

.odx-pp-thumb img {
  width: 100%;
  height: auto;
  display: block;
}

.odx-pp-content {
  background: #fff;
  border-radius: 16px;
  padding: 32px;
  border: 1px solid #e8eef3;
  line-height: 1.75;
  color: #1A1A2E;
  font-size: 0.98rem;
}

.odx-pp-content > *:first-child {
  margin-top: 0;
}

.odx-pp-content > *:last-child {
  margin-bottom: 0;
}

.odx-pp-content p {
  margin: 0 0 1em;
}

.odx-pp-content h2,
.odx-pp-content h3,
.odx-pp-content h4 {
  color: #1A1A2E;
  font-weight: 700;
  margin-top: 1.5em;
  margin-bottom: 0.6em;
  line-height: 1.35;
}

.odx-pp-content h2 {
  font-size: 1.25rem;
}

.odx-pp-content h3 {
  font-size: 1.1rem;
}

.odx-pp-content h4 {
  font-size: 1rem;
}

.odx-pp-content strong,
.odx-pp-content b {
  font-weight: 700;
  color: #1A1A2E;
}

.odx-pp-content ul,
.odx-pp-content ol {
  margin: 0 0 1.2em;
  padding-left: 1.4em;
}

.odx-pp-content ul {
  list-style: disc;
}

.odx-pp-content ol {
  list-style: decimal;
}

.odx-pp-content li {
  margin-bottom: 0.45em;
  padding-left: 0.15em;
  line-height: 1.6;
}

.odx-pp-content li::marker {
  color: #18cb96;
}

.odx-pp-content a {
  color: #0097b2;
  text-decoration: underline;
}

.odx-pp-content a:hover {
  color: #18cb96;
}

.odx-pp-content img {
  max-width: 100%;
  height: auto;
  border-radius: 10px;
  margin: 1em 0;
}

.odx-pp-content blockquote {
  margin: 1.2em 0;
  padding: 12px 18px;
  border-left: 3px solid #18cb96;
  background: #f7fafc;
  color: #5a5a72;
  border-radius: 0 8px 8px 0;
}

.odx-pp-aside-card {
  background: #fff;
  border-radius: 20px;
  padding: 32px 28px;
  border: 1.5px solid #e8eef3;
  position: sticky;
  top: 100px;
}

.odx-pp-single-title {
  font-size: 1.5rem;
  font-weight: 800;
  margin: 0 0 12px;
  color: #1A1A2E;
  line-height: 1.3;
}

.odx-pp-aside-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 8px;
}

.odx-pp-back {
  margin-top: 48px;
  text-align: center;
}

.odx-pp-back a {
  color: #0097b2;
  text-decoration: none;
  font-weight: 600;
}

.odx-pp-back a:hover {
  text-decoration: underline;
}

/* Responsive */
@media (max-width: 992px) {
  .odx-pp-grid {
    grid-template-columns: 1fr;
    max-width: 440px;
    margin: 0 auto;
  }

  .odx-pp-single-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .odx-pp-main-col {
    display: contents;
  }

  .odx-pp-thumb {
    order: 1;
  }

  .odx-pp-single-aside {
    order: 2;
  }

  .odx-pp-content {
    order: 3;
  }

  .odx-pp-aside-card {
    position: static;
  }
}

@media (max-width: 600px) {
  .odx-pp-archive,
  .odx-pp-single {
    padding: 100px 0 60px;
  }
}
