/* =========================================================
   Dr. Austin — Product Detail Page Styles
   Visual reference: CoQ10 third-level page
   Top section · Badges · Highlight · Ingredients · Also-like · FAQ
   ========================================================= */

.detail-main {
  background: #fff;
}

.detail-inner {
  width: var(--container);
  margin: 0 auto;
  padding: 44px 0 120px;
}

/* ---------- Top: media + info ---------- */
.detail-top {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: 56px;
  align-items: center;
}
.detail-media {
  background: linear-gradient(180deg, var(--yellow-soft) 0%, var(--cream-2) 100%);
  border-radius: var(--r-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px 48px;
}
.detail-media img {
  width: min(400px, 88%);
  height: 380px;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.detail-info h1 {
  margin: 0 0 14px;
  color: var(--ink);
  font-size: clamp(26px, 2.4vw, 40px);
  font-weight: 600;
  line-height: 1.15;
  text-align: left;
}
.detail-desc {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.75;
  max-width: 560px;
}
.detail-price {
  margin-bottom: 22px;
  color: #1d2d59;
  font-size: 30px;
  font-weight: 600;
}

/* Plan toggle */
.plan-toggle {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}
.plan {
  flex: 1;
  max-width: 260px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  padding: 14px 18px;
  border: 1.5px solid var(--line);
  border-radius: var(--r-md);
  background: var(--white);
  color: #43537b;
  font-size: 13px;
  text-align: left;
  transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
}
.plan strong {
  color: #1d2d59;
  font-size: 16px;
  font-weight: 600;
}
.plan:hover { border-color: var(--yellow-strong); }
.plan.is-active {
  background: var(--yellow);
  border-color: var(--yellow);
  box-shadow: 0 8px 24px rgba(255, 209, 44, 0.35);
}

/* Perks */
.plan-perks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 18px 0;
}
.plan-perks li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #5a6788;
  font-size: 12.5px;
  font-weight: 600;
}
.plan-perks svg {
  width: 14px;
  height: 14px;
  color: var(--green);
  stroke-width: 3;
}

.subscribe-tag {
  display: inline-block;
  margin-bottom: 20px;
  padding: 10px 40px;
  border-radius: var(--r-pill);
  background: var(--yellow);
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
}

/* Cart row */
.cart-row {
  display: flex;
  align-items: center;
  gap: 14px;
}
.qty {
  display: flex;
  align-items: center;
  height: 50px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: var(--white);
  overflow: hidden;
}
.qty button {
  width: 44px;
  height: 100%;
  color: #43537b;
  font-size: 18px;
  font-weight: 700;
  transition: background .2s ease;
}
.qty button:hover { background: var(--soft); }
.qty span {
  min-width: 34px;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  color: #1d2d59;
}
.add-cart {
  flex: 1;
  max-width: 300px;
  height: 50px;
  border-radius: var(--r-pill);
  background: var(--navy);
  color: var(--yellow);
  font-size: 16px;
  font-weight: 600;
  transition: background .2s ease, transform .2s ease;
}
.add-cart:hover { background: var(--navy-deep); transform: scale(1.02); }

/* ---------- Quality badges ---------- */
.detail-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin: 56px 0 64px;
}
.badge {
  padding: 10px 20px;
  border-radius: var(--r-pill);
  background: var(--white);
  border: 1px solid var(--line-2);
  color: #43537b;
  font-size: 12.5px;
  font-weight: 700;
  box-shadow: var(--shadow-sm);
}

/* ---------- Highlight ---------- */
.detail-highlight {
  text-align: center;
  padding: 64px 40px;
  border-radius: var(--r-lg);
  background: linear-gradient(180deg, var(--yellow-soft) 0%, var(--cream-2) 100%);
  margin-bottom: 96px;
}
.detail-highlight h2 {
  margin: 0 0 18px;
  color: var(--ink);
  font-size: clamp(26px, 2.6vw, 42px);
  font-weight: 600;
}
.detail-highlight p {
  max-width: 760px;
  margin: 0 auto 10px;
  color: #4a5677;
  font-size: 14px;
  line-height: 1.8;
}
.detail-highlight .hl-sub {
  color: var(--muted);
  font-size: 13px;
}
.hl-report {
  display: inline-block;
  margin-top: 20px;
  padding: 12px 26px;
  border-radius: var(--r-pill);
  background: var(--navy);
  color: var(--white);
  font-size: 13px;
  font-weight: 600;
  transition: background .2s ease, transform .2s ease;
}
.hl-report:hover { background: var(--navy-deep); color: var(--white); transform: translateY(-2px); }

/* ---------- Ingredients ---------- */
.detail-ingredients { margin-bottom: 96px; }
.detail-ingredients h2 { margin-bottom: 44px; }
.ing-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.ing-card {
  padding: 30px 34px;
  border-radius: var(--r-lg);
  background: var(--white);
  border: 1px solid var(--line-2);
  box-shadow: var(--shadow-sm);
}
.ing-card h3 {
  margin: 0 0 12px;
  color: var(--ink);
  font-size: 18px;
  font-weight: 600;
}
.ing-card h3 span {
  margin-left: 8px;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  background: var(--yellow);
  color: var(--ink);
  font-size: 12px;
  font-weight: 600;
  vertical-align: 2px;
}
.ing-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.75;
}

/* ---------- You May Also Like ---------- */
.detail-also { margin-bottom: 96px; }
.detail-also h2 { margin-bottom: 44px; }
.also-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
.also-card {
  display: block;
  padding: 22px 22px 20px;
  border-radius: var(--r-lg);
  border: 1px solid var(--line-2);
  transition: transform .25s ease, box-shadow .25s ease;
}
.also-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  color: inherit;
}
.also-media {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 190px;
  margin-bottom: 18px;
  background: linear-gradient(180deg, var(--yellow-soft) 0%, var(--cream-2) 100%);
}
.also-media img {
  height: 170px;
  width: auto;
  object-fit: contain;
  mix-blend-mode: multiply;
}
.also-name {
  display: block;
  min-height: 40px;
  margin-bottom: 16px;
  color: #43537b;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.45;
}
.also-buy {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.also-buy strong {
  color: #1d2d59;
  font-size: 17px;
  font-weight: 600;
}
.add-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 54px;
  height: 30px;
  padding: 0 14px;
  border-radius: var(--r-pill);
  background: var(--yellow);
  color: var(--ink);
  font-size: 12px;
  font-weight: 600;
}

/* ---------- FAQ ---------- */
.detail-faqs h2 { margin-bottom: 40px; }
.faq-list {
  max-width: 860px;
  margin: 0 auto;
}
.faq-item {
  border-bottom: 1px solid var(--yellow-strong);
}
.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 6px;
  text-align: left;
  color: var(--ink);
  font-size: 15px;
  font-weight: 700;
  transition: color .2s ease;
}
.faq-q:hover { color: var(--navy); }
.faq-q svg {
  flex: none;
  width: 26px;
  height: 26px;
  padding: 5px;
  border-radius: 50%;
  background: var(--yellow);
  color: var(--ink);
  stroke-width: 2.6;
  transition: transform .25s ease;
}
.faq-item.is-open .faq-q svg { transform: rotate(180deg); }
.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease;
}
.faq-a p {
  margin: 0;
  padding: 0 6px 22px;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.8;
}
.faq-item.is-open .faq-a { max-height: 320px; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .detail-top { gap: 36px; }
  .detail-media { padding: 40px 32px; }
  .detail-media img { height: 320px; }
  .also-grid { gap: 20px; }
}

@media (max-width: 900px) {
  .detail-inner { padding: 30px 0 64px; }
  .detail-top { grid-template-columns: 1fr; gap: 28px; }
  .detail-media { padding: 32px 24px; }
  .detail-media img { height: 260px; }
  .detail-badges { margin: 40px 0 44px; }
  .detail-highlight { padding: 44px 24px; margin-bottom: 64px; }
  .detail-ingredients { margin-bottom: 64px; }
  .detail-also { margin-bottom: 64px; }
  .ing-grid { grid-template-columns: 1fr; gap: 16px; }
  .also-grid { grid-template-columns: 1fr; gap: 18px; }
  .also-card { max-width: 440px; margin: 0 auto; }
  .cart-row { flex-wrap: wrap; }
  .add-cart { min-width: 200px; }
}

@media (max-width: 520px) {
  .detail-info h1 { font-size: 22px; }
  .plan-toggle { flex-direction: column; }
  .plan { max-width: none; }
  .detail-highlight h2 { font-size: 22px; }
  .ing-card { padding: 22px 20px; }
  .badge { padding: 8px 14px; font-size: 11.5px; }
  .faq-q { font-size: 13.5px; }
}
