/**
 * SMARTDOCIFY SHOP STYLES - PRODUCTION
 */

.shop-hero {
  padding: 4rem 0 2.5rem 0;
  text-align: center;
  background: radial-gradient(circle at 50% 10%, rgba(37, 99, 235, 0.08) 0%, transparent 65%);
}

.shop-search-wrapper {
  max-width: 600px;
  margin: 1.75rem auto 0 auto;
  position: relative;
}

.shop-search-input {
  width: 100%;
  padding: 0.9rem 1.25rem 0.9rem 2.85rem;
  font-size: 1rem;
  border-radius: var(--radius-full, 9999px);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  color: var(--text-main);
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
}

.shop-search-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.15);
}

.shop-search-icon {
  position: absolute;
  left: 1.1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-subtle);
  pointer-events: none;
}

/* Filter Toolbar */
.shop-filters-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
}

.shop-category-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.shop-pill {
  padding: 0.45rem 1rem;
  border-radius: var(--radius-full, 9999px);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.shop-pill:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(37, 99, 235, 0.04);
}

.shop-pill.active {
  background: var(--primary);
  color: #FFFFFF;
  border-color: var(--primary);
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

.shop-sub-pill {
  padding: 0.3rem 0.85rem;
  border-radius: var(--radius-full, 9999px);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.shop-sub-pill:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(37, 99, 235, 0.04);
}

.shop-sub-pill.active {
  background: rgba(37, 99, 235, 0.12);
  color: var(--primary);
  border-color: var(--primary);
  font-weight: 700;
}

.shop-type-pills {
  display: inline-flex;
  background: var(--bg-surface-alt);
  padding: 3px;
  border-radius: var(--radius-full, 9999px);
  border: 1px solid var(--border-subtle);
}

.shop-type-btn {
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full, 9999px);
  border: none;
  background: transparent;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s ease;
}

.shop-type-btn.active {
  background: var(--bg-surface);
  color: var(--text-main);
  box-shadow: var(--shadow-sm);
}

/* Products Grid */
.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.product-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(37, 99, 235, 0.4);
}

.product-card-preview {
  height: 220px;
  background: var(--bg-surface-alt);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  position: relative;
  border-bottom: 1px solid var(--border-subtle);
  overflow: hidden;
}

.product-card-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.product-card:hover .product-card-preview img {
  transform: scale(1.04);
}

.product-watermark-pill {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(4px);
  color: #FFFFFF;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-xs);
  letter-spacing: 0.05em;
  z-index: 2;
}

.product-featured-pill {
  position: absolute;
  top: 12px;
  left: 12px;
  background: linear-gradient(135deg, #F59E0B, #D97706);
  color: #FFFFFF;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-xs);
  letter-spacing: 0.05em;
  z-index: 2;
}

.product-card-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.product-card-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-size: 0.78rem;
  color: var(--text-subtle);
}

.product-card-title {
  font-size: 1.18rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--text-main);
  line-height: 1.35;
}

.product-card-title a {
  color: inherit;
  text-decoration: none;
}

.product-card-title a:hover {
  color: var(--primary);
}

.product-card-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

.product-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  border-top: 1px solid var(--border-subtle);
  padding-top: 1rem;
  gap: 0.75rem;
}

.product-price-box {
  display: flex;
  flex-direction: column;
}

.product-price {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1;
}

.product-price-free {
  color: var(--accent-emerald, #10B981);
}

.product-price-sale {
  color: #EF4444;
}

.product-price-orig {
  font-size: 0.82rem;
  color: var(--text-subtle);
  text-decoration: line-through;
  margin-top: 2px;
}

.product-card-actions {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

/* ==========================================================================
   Product Detail Page Styles
   ========================================================================== */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-subtle);
  margin-bottom: 2rem;
  padding: 0.5rem 0;
}

.breadcrumb a {
  color: var(--text-muted);
  text-decoration: none;
}

.breadcrumb a:hover {
  color: var(--primary);
}

.product-detail-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.5rem;
  align-items: start;
}

.product-preview-pane {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 2rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.sample-watermark-overlay {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(4px);
  color: #FFFFFF;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-xs);
  letter-spacing: 0.06em;
}

.product-preview-pane img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-md);
  margin-bottom: 1.5rem;
}

.product-preview-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.product-meta-specs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  background: var(--bg-surface-alt);
  padding: 1.25rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  margin: 1.5rem 0;
  font-size: 0.88rem;
}

.product-meta-specs dt {
  font-weight: 600;
  color: var(--text-subtle);
}

.product-meta-specs dd {
  margin: 0;
  font-weight: 700;
  color: var(--text-main);
  text-align: right;
}

.product-description-content {
  font-size: 0.95rem;
  color: var(--text-main);
  line-height: 1.7;
  margin: 1.5rem 0;
}

.product-description-content h3 {
  font-size: 1.15rem;
  font-weight: 800;
  margin: 1.5rem 0 0.75rem 0;
}

.product-description-content ul {
  padding-left: 1.25rem;
  margin: 0.75rem 0;
}

.product-description-content li {
  margin-bottom: 0.5rem;
}

/* Related sections */
.related-section {
  margin-top: 4rem;
  padding-top: 3rem;
  border-top: 1px solid var(--border-subtle);
}

.related-section-header {
  margin-bottom: 1.75rem;
}

.related-section-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-main);
}

.related-tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}

.related-tool-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
}

.related-tool-card:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

.related-tool-icon {
  width: 44px;
  height: 44px;
  background: rgba(37, 99, 235, 0.08);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}

.related-blogs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

.related-blog-card {
  padding: 1.25rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
}

.related-blog-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}

/* Sample Preview Modal */
.shop-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(4px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.shop-modal-box {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  width: 100%;
  max-width: 780px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: var(--shadow-2xl, 0 25px 50px -12px rgba(0, 0, 0, 0.25));
}

.shop-modal-header {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.shop-modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
}

.shop-modal-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-surface-alt);
}

@media (max-width: 900px) {
  .product-detail-layout {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}