/**
 * Product Detail Page Master Stylesheet - Hindustan Power EV
 * Inspired by Chetak, Ather, Ola, Tesla & Apple EV design language.
 *
 * @package HindustanPowerEV
 * @version 4.0.0
 */

/* ==========================================================================
   1. Page Layout & Breadcrumb Bar
   ========================================================================== */
.hp-pd-page {
  background-color: #f8fafc;
  color: #0f172a;
  padding-top: 100px;
}

.hp-pd-breadcrumbs-bar {
  padding: 1.25rem 0;
  font-size: 0.85rem;
  color: #64748b;
  border-bottom: 1px solid #e2e8f0;
  background: #ffffff;
  margin-bottom: 2rem;
}

.hp-pd-breadcrumbs-bar a {
  color: #64748b;
  text-decoration: none;
  transition: color 0.2s ease;
}

.hp-pd-breadcrumbs-bar a:hover {
  color: #11b2a4;
}

.hp-pd-breadcrumbs-bar span.sep {
  margin: 0 0.5rem;
  color: #cbd5e1;
}

.hp-pd-breadcrumbs-bar span.current {
  color: #0f172a;
  font-weight: 600;
}

/* ==========================================================================
   2. Main Showcase Hero (2-Column Desktop Layout)
   ========================================================================== */
.hp-pd-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 2rem;
  align-items: start;
  margin-bottom: 4rem;
  width: 100%;
}

/* Left Column: Gallery Container */
.hp-pd-gallery-container {
  position: relative;
  background: #ffffff;
  border-radius: 24px;
  border: 1px solid #e2e8f0;
  padding: 2rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.04);
  min-width: 0;
}

.hp-pd-badge {
  position: absolute;
  top: 1.5rem;
  left: 1.5rem;
  background: #11b2a4;
  color: #ffffff;
  font-family: 'Outfit', sans-serif;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0.35rem 0.85rem;
  border-radius: 6px;
  z-index: 10;
}

/* Floating Action Glass Bar (360, Zoom, Fullscreen) */
.hp-pd-floating-actions {
  position: absolute;
  top: 1.5rem;
  left: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  z-index: 12;
}

.hp-pd-badge-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.hp-pd-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: 12px;
  color: #334155;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
}

.hp-pd-action-btn:hover {
  background: #11b2a4;
  color: #ffffff;
  border-color: #11b2a4;
  transform: scale(1.05);
}

.hp-pd-action-btn svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.hp-pd-action-btn span {
  font-size: 0.6rem;
  font-weight: 700;
  margin-top: 0.2rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Hero Main Image Stage */
.hp-pd-hero-stage {
  position: relative;
  width: 100%;
  height: 420px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-bottom: 1.5rem;
}

.hp-pd-hero-stage img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: zoom-in;
}

.hp-pd-hero-stage:hover img {
  transform: scale(1.04);
}

/* Gallery Arrows */
.hp-pd-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #e2e8f0;
  color: #0f172a;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: all 0.2s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.hp-pd-arrow:hover {
  background: #11b2a4;
  color: #ffffff;
  border-color: #11b2a4;
}

.hp-pd-arrow-prev { left: 1rem; }
.hp-pd-arrow-next { right: 1rem; }

/* Image Counter Pill */
.hp-pd-counter {
  position: absolute;
  bottom: 7.25rem;
  left: 2rem;
  font-family: 'Outfit', sans-serif;
  font-size: 0.75rem;
  font-weight: 700;
  color: #64748b;
  z-index: 10;
}

.hp-pd-counter span.active {
  color: #0f172a;
  font-size: 0.85rem;
}

/* Thumbnail Carousel Strip */
.hp-pd-thumbs-strip {
  display: flex;
  align-items: center;
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scrollbar-width: thin;
}

.hp-pd-thumb-item {
  width: 90px;
  height: 70px;
  border-radius: 12px;
  border: 2px solid #e2e8f0;
  background: #f8fafc;
  padding: 0.4rem;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hp-pd-thumb-item img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.hp-pd-thumb-item:hover,
.hp-pd-thumb-item.is-active {
  border-color: #11b2a4;
  box-shadow: 0 4px 12px rgba(17, 178, 164, 0.25);
  background: #ffffff;
}

/* ==========================================================================
   3. Right Column: Sticky Purchase Details Card
   ========================================================================== */
.hp-pd-details-card {
  background: #ffffff;
  border-radius: 24px;
  border: 1px solid #e2e8f0;
  padding: 2.25rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.04);
  position: sticky;
  top: 110px;
  min-width: 0;
}

.hp-pd-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.5rem;
}

.hp-pd-title {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(1.85rem, 3vw, 2.35rem);
  font-weight: 800;
  color: #0f172a;
  line-height: 1.1;
}

.hp-pd-wishlist-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #64748b;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.hp-pd-wishlist-btn:hover {
  color: #ef4444;
  border-color: #fca5a5;
  background: #fef2f2;
}

.hp-pd-rating-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: #64748b;
  margin-bottom: 0.75rem;
}

.hp-pd-stars {
  color: #f59e0b;
}

.hp-pd-subtitle {
  font-size: 0.95rem;
  color: #64748b;
  margin-bottom: 1.5rem;
  line-height: 1.5;
}

/* Quick Specs Pills Row */
.hp-pd-specs-pills {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
  margin-bottom: 1.75rem;
  background: #f8fafc;
  padding: 1rem;
  border-radius: 16px;
  border: 1px solid #f1f5f9;
}

.hp-pd-spec-pill {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hp-pd-spec-pill svg {
  width: 18px;
  height: 18px;
  color: #11b2a4;
  flex-shrink: 0;
}

.hp-pd-spec-val {
  font-family: 'Outfit', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1;
}

.hp-pd-spec-lbl {
  font-size: 0.675rem;
  color: #94a3b8;
  display: block;
  margin-top: 0.15rem;
}

/* Price Box */
.hp-pd-price-box {
  margin-bottom: 1.75rem;
}

.hp-pd-price-wrap {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  margin-bottom: 0.25rem;
}

.hp-pd-price {
  font-family: 'Outfit', sans-serif;
  font-size: 2.25rem;
  font-weight: 900;
  color: #11b2a4;
  line-height: 1;
}

.hp-pd-original-price {
  font-size: 1.1rem;
  color: #94a3b8;
  text-decoration: line-through;
}

.hp-pd-ex-note {
  font-size: 0.75rem;
  color: #64748b;
}

/* Color Variant Swatches */
.hp-pd-color-section {
  margin-bottom: 1.75rem;
}

.hp-pd-color-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 0.75rem;
}

.hp-pd-color-label span {
  font-weight: 500;
  color: #64748b;
}

.hp-pd-swatches {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.hp-pd-swatch {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid #e2e8f0;
  cursor: pointer;
  position: relative;
  transition: all 0.2s ease;
}

.hp-pd-swatch.is-active,
.hp-pd-swatch:hover {
  transform: scale(1.15);
  box-shadow: 0 0 0 3px rgba(17, 178, 164, 0.35);
  border-color: #11b2a4;
}

/* Primary CTAs */
.hp-pd-cta-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-bottom: 1.75rem;
}

.hp-pd-btn-primary {
  background: #11b2a4;
  color: #ffffff;
  border: none;
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 1rem 1.75rem;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  transition: all 0.25s ease;
  box-shadow: 0 8px 24px rgba(17, 178, 164, 0.3);
}

.hp-pd-btn-primary:hover {
  background: #0ea194;
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(17, 178, 164, 0.4);
}

.hp-pd-btn-outline {
  background: transparent;
  color: #11b2a4;
  border: 2px solid #11b2a4;
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.9rem 1.75rem;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  transition: all 0.25s ease;
}

.hp-pd-btn-outline:hover {
  background: rgba(17, 178, 164, 0.08);
  transform: translateY(-2px);
}

/* Utility Links Row */
.hp-pd-utility-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid #f1f5f9;
  font-size: 0.775rem;
  color: #64748b;
}

.hp-pd-utility-link {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: #64748b;
  text-decoration: none;
  transition: color 0.2s ease;
}

.hp-pd-utility-link:hover {
  color: #11b2a4;
}

.hp-pd-utility-link svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
}

/* ==========================================================================
   4. Master Content Tabs Section
   ========================================================================== */
.hp-pd-tabs-wrapper {
  margin-bottom: 5rem;
}

.hp-pd-tabs-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
  border-bottom: 2px solid #e2e8f0;
  margin-bottom: 3rem;
  overflow-x: auto;
}

.hp-pd-tab-btn {
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #64748b;
  background: transparent;
  border: none;
  padding: 1rem 0;
  position: relative;
  cursor: pointer;
  transition: color 0.2s ease;
  white-space: nowrap;
}

.hp-pd-tab-btn::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0%;
  height: 3px;
  background: #11b2a4;
  transition: width 0.25s ease;
}

.hp-pd-tab-btn.is-active,
.hp-pd-tab-btn:hover {
  color: #11b2a4;
}

.hp-pd-tab-btn.is-active::after {
  width: 100%;
}

.hp-pd-tab-panel {
  display: none;
}

.hp-pd-tab-panel.is-active {
  display: block;
}

/* Overview Tab Grid */
.hp-pd-overview-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr 0.9fr;
  gap: 2.5rem;
  align-items: start;
}

.hp-pd-overview-card {
  background: #ffffff;
  border-radius: 20px;
  border: 1px solid #e2e8f0;
  padding: 2rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
}

.hp-pd-overview-card h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.35rem;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 1rem;
}

.hp-pd-overview-card p {
  font-size: 0.95rem;
  color: #64748b;
  line-height: 1.65;
  margin-bottom: 1.75rem;
}

.hp-pd-feature-pills-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.hp-pd-feature-pill-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: #f8fafc;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border: 1px solid #f1f5f9;
}

.hp-pd-feature-pill-item svg {
  width: 22px;
  height: 22px;
  color: #11b2a4;
  flex-shrink: 0;
}

.hp-pd-feature-pill-item h4 {
  font-size: 0.85rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.hp-pd-feature-pill-item p {
  font-size: 0.725rem;
  color: #94a3b8;
  margin: 0;
  line-height: 1.2;
}

/* Quick Specs Table */
.hp-pd-quick-specs-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
}

.hp-pd-quick-specs-table tr {
  border-bottom: 1px solid #f1f5f9;
}

.hp-pd-quick-specs-table td {
  padding: 0.75rem 0;
  font-size: 0.85rem;
}

.hp-pd-quick-specs-table td.lbl {
  color: #64748b;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hp-pd-quick-specs-table td.val {
  color: #0f172a;
  font-weight: 700;
  text-align: right;
}

/* Key Highlights Card */
.hp-pd-highlights-list {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.hp-pd-highlight-item {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
}

.hp-pd-highlight-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: rgba(17, 178, 164, 0.1);
  color: #11b2a4;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.hp-pd-highlight-item h4 {
  font-size: 0.9rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 0.2rem;
}

.hp-pd-highlight-item p {
  font-size: 0.775rem;
  color: #64748b;
  margin: 0;
}

/* Categorized Specifications Accordion / Table */
.hp-pd-full-specs-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

.hp-pd-specs-cat-card {
  background: #ffffff;
  border-radius: 20px;
  border: 1px solid #e2e8f0;
  padding: 1.75rem;
}

.hp-pd-specs-cat-card h4 {
  font-size: 1.1rem;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 1.25rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #11b2a4;
  display: inline-block;
}

/* Interactive 360 Rotation Modal */
.hp-360-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(11, 13, 25, 0.92);
  backdrop-filter: blur(15px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: all 0.35s ease;
}

.hp-360-modal.is-active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.hp-360-stage {
  position: relative;
  width: 90%;
  max-width: 800px;
  height: 500px;
  background: #ffffff;
  border-radius: 24px;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
}

.hp-360-close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #f1f5f9;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
}

.hp-360-canvas-wrap {
  width: 100%;
  height: 380px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
}

.hp-360-canvas-wrap:active {
  cursor: grabbing;
}

.hp-360-canvas-wrap img {
  max-height: 100%;
  object-fit: contain;
}

.hp-360-hint {
  font-size: 0.8rem;
  color: #64748b;
  margin-top: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Responsive Mobile & Laptop Rules */
@media (max-width: 1440px) {
  .hp-pd-hero-grid {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    gap: 1.5rem;
  }
  .hp-pd-gallery-container,
  .hp-pd-details-card {
    padding: 1.5rem;
  }
  .hp-pd-specs-pills {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.6rem;
  }
}

@media (max-width: 1200px) {
  .hp-pd-hero-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 1.25rem;
  }
  .hp-pd-gallery-container,
  .hp-pd-details-card {
    padding: 1.25rem;
  }
}

@media (max-width: 1024px) {
  .hp-pd-hero-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .hp-pd-details-card {
    position: static;
  }

  .hp-pd-overview-grid {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }

  .hp-pd-full-specs-grid {
    grid-template-columns: 1fr;
  }

  .hp-pd-specs-pills {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 576px) {
  .hp-pd-gallery-container {
    padding: 1rem;
  }

  .hp-pd-hero-stage {
    height: 300px;
  }

  .hp-pd-feature-pills-grid {
    grid-template-columns: 1fr;
  }
}
