/* Shared CSS for all product detail pages */
:root {
  --page: var(--primary-bg, #1a1a2e);
  --card: rgba(31, 40, 51, 0.4);
  --border: rgba(212, 175, 55, 0.2);
  --accent: #d4af37;
  --r-sm: 4px;
}

.canvas {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0;
  position: relative;
  z-index: 2;
}

.form-header {
  margin-bottom: 40px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
  text-align: center;
}

.form-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.5rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 10px;
  text-align: left;
  line-height: 1.2;
}

.form-group {
  margin-bottom: 20px;
}

.form-label {
  color: #e0e0e0;
  margin-bottom: 8px;
  font-weight: 500;
}

.form-control {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border);
  color: #fff;
  padding: 12px;
  border-radius: var(--r-sm);
}

.form-control:focus {
  background: rgba(0, 0, 0, 0.5);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.15);
}

.btn-submit {
  background: var(--accent);
  color: #000;
  border: none;
  padding: 12px 24px;
  font-weight: 600;
  text-transform: uppercase;
  width: 100%;
  margin-top: 20px;
  transition: all 0.2s;
}

.btn-submit:hover {
  background: #b4942b;
  color: #000;
}

#result-container {
  margin-top: 30px;
  padding: 20px;
  background: rgba(46, 168, 115, 0.1);
  border: 1px solid #2ea873;
  border-radius: var(--r-sm);
  display: none;
}

.result-title {
  color: #2ea873;
  font-weight: 600;
  margin-bottom: 10px;
}

.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, .8);
  backdrop-filter: blur(5px);
  z-index: 3000;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 20px;
}

.loading-overlay.show {
  display: flex;
}

.loading-text {
  color: var(--accent);
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.5rem;
  letter-spacing: 2px;
}

/* UI/UX Improvements */

/* Breadcrumbs */
.breadcrumb-nav {
  margin-bottom: 20px;
  font-size: 0.9rem;
  color: #e0e0e0;
}
.breadcrumb-nav a {
  color: var(--accent);
  text-decoration: none;
}
.breadcrumb-nav a:hover {
  text-decoration: underline;
}
.breadcrumb-nav span {
  margin: 0 5px;
  color: #666;
}

/* Price Display */
.price-badge {
  display: inline-block;
  background: rgba(212, 175, 55, 0.1);
  border: 1px solid var(--accent);
  color: var(--accent);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 5px;
}
.price-usd {
  display: block;
  font-size: 0.9rem;
  color: #a0a0a0;
  margin-bottom: 25px;
}

/* Features List */
.features-section ul {
  list-style: none;
  padding: 0;
  margin: 0 0 25px 0;
}
.features-section li {
  margin-bottom: 10px;
  color: #e0e0e0;
  display: flex;
  align-items: center;
}
.features-section li i {
  color: var(--accent);
  margin-right: 10px;
  font-size: 1.1rem;
}

.features-separator {
  border-top: 1px solid var(--border);
  margin: 20px 0;
}

/* Order Form Panel */
.order-form-panel {
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 20px;
  margin-top: 30px;
}
.order-form-panel h3 {
  color: var(--accent);
  font-size: 1.5rem;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 10px;
}

/* Segmented Control for Radio Buttons */
.custom-segmented-control {
  display: flex;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  overflow: hidden;
}
.custom-segmented-control input[type="radio"] {
  display: none;
}
.custom-segmented-control label {
  flex: 1;
  text-align: center;
  padding: 10px;
  cursor: pointer;
  color: #fff;
  transition: all 0.2s;
  border-right: 1px solid var(--border);
  margin: 0;
}
.custom-segmented-control label:last-child {
  border-right: none;
}
.custom-segmented-control input[type="radio"]:checked + label {
  background: var(--accent);
  color: #000;
  font-weight: 600;
}

/* Character Counter */
.char-counter {
  display: block;
  text-align: right;
  font-size: 0.8rem;
  color: #a0a0a0;
  margin-top: 5px;
}

/* Trust Signals */
.trust-signals {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  margin-top: 25px;
  border-top: 1px solid var(--border);
  padding-top: 15px;
}
.trust-signal-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  font-size: 0.8rem;
  color: #a0a0a0;
  width: 25%;
  min-width: 80px;
}
.trust-signal-item i {
  font-size: 1.2rem;
  color: var(--accent);
  margin-bottom: 5px;
}

/* Iframe Skeleton Loader */
.iframe-skeleton {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #111 25%, #222 50%, #111 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  z-index: 1;
}
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.demo-thumbnail-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 3/4;
  border: 1px solid var(--border);
  border-radius: 4px;
  margin-bottom: 15px;
  cursor: pointer;
  background: rgba(31, 40, 51, 0.4);
  overflow: hidden;
  transition: all 0.2s ease;
}
.demo-thumbnail-wrapper.active {
  border-color: var(--accent);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.2);
}
.demo-thumbnail-wrapper:hover {
  border-color: rgba(212, 175, 55, 0.5);
}
.demo-thumbnail-iframe {
  width: 400%;
  height: 400%;
  transform: scale(0.25);
  transform-origin: top left;
  border: none;
  pointer-events: none;
}
.demo-thumbnail-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.3);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}
.demo-thumbnail-label {
  background: rgba(0,0,0,0.7);
  color: var(--accent);
  padding: 5px 10px;
  border-radius: 4px;
  font-size: 0.8rem;
  text-align: center;
}

/* Layout stacking on mobile */
@media (max-width: 991px) {
  #mainContent {

  }
  .product-info-wrapper {
    margin-bottom: 30px;
    padding-left: 0 !important;
  }
  .demo-gallery-container {
    margin-bottom: 20px;
  }

  /* Sticky CTA on Mobile */
  .mobile-sticky-cta-container {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(15, 20, 25, 0.95);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--border);
    padding: 15px 20px;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 -5px 20px rgba(0,0,0,0.5);
  }
  .mobile-sticky-price {
    color: var(--accent);
    font-size: 1.2rem;
    font-weight: bold;
    margin: 0;
  }
  .mobile-sticky-btn {
    margin-top: 0;
    width: auto;
    padding: 10px 30px;
  }

  /* Add padding to body to prevent content from hiding behind sticky bar */
  body {
    padding-bottom: 80px;
  }
}
@media (min-width: 992px) {
  .mobile-sticky-cta-container {
    display: none;
  }
}
