/* ===== PRODUCT DETAIL PAGE ===== */

.product-detail-page {
  padding-top: 80px;
  padding-bottom: 40px;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
  margin-bottom: 16px;
}

.back-link:hover {
  color: var(--text-primary);
  background: var(--bg-tertiary);
}

/* ===== PRODUCT HERO ===== */
.product-hero {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 24px;
  align-items: center;
  margin-bottom: 32px;
  padding: 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  position: relative;
  overflow: hidden;
}

.product-hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(234,67,53,0.06) 0%, transparent 70%);
  pointer-events: none;
}

.product-logo-large {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 44px;
  flex-shrink: 0;
  box-shadow: var(--shadow-md);
  position: relative;
  z-index: 1;
}

.product-info-main {
  position: relative;
  z-index: 1;
}

.product-name {
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 6px;
  letter-spacing: -0.02em;
}

.product-maker {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

.product-tagline {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
  max-width: 500px;
}

.product-badges {
  display: flex;
  gap: 6px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.badge {
  padding: 4px 12px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

.badge-hot {
  background: rgba(248,113,113,0.15);
  border-color: rgba(248,113,113,0.3);
  color: var(--accent-red);
}

.badge-new {
  background: rgba(74,222,128,0.15);
  border-color: rgba(74,222,128,0.3);
  color: var(--accent-green);
}

.badge-free {
  background: rgba(250,204,21,0.15);
  border-color: rgba(250,204,21,0.3);
  color: var(--accent-yellow);
}

.badge-open {
  background: rgba(84,160,255,0.15);
  border-color: rgba(84,160,255,0.3);
  color: var(--accent-blue);
}

.badge-featured {
  background: rgba(255,99,72,0.15);
  border-color: rgba(255,99,72,0.3);
  color: var(--accent-orange);
}

/* ===== RATING CARD ===== */
.rating-card {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 20px;
  text-align: center;
  min-width: 160px;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.rating-letter {
  font-size: 42px;
  font-weight: 900;
  line-height: 1;
}

.rating-letter.s { color: var(--accent-red); }
.rating-letter.a { color: var(--accent-orange); }
.rating-letter.b { color: var(--accent-yellow); }
.rating-letter.c { color: var(--text-muted); }

.rating-label {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 600;
}

.rating-stars {
  font-size: 14px;
  margin-bottom: 8px;
}

/* ===== PRODUCT ACTIONS ===== */
.product-actions {
  display: flex;
  flex-direction: row;
  gap: 8px;
  width: 100%;
  margin-top: 4px;
}

.product-actions .btn {
  flex: 1;
  padding: 8px 12px;
  font-size: 13px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition-fast);
  cursor: pointer;
  border: none;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-red), var(--accent-orange));
  color: white;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
}

.btn-secondary {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--border-color);
}

/* ===== CONTENT GRID ===== */
.content-grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 24px;
  align-items: start;
}

/* ===== SECTIONS ===== */
.section {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 16px;
}

.section:hover {
  box-shadow: var(--shadow-sm);
}

.section-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-title .icon {
  font-size: 18px;
}

.description-text {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.8;
}

/* ===== FEATURES LIST ===== */
.features-list {
  list-style: none;
}

.feature-item {
  align-items: flex-start;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-color);
}

.feature-item:last-child {
  border-bottom: none;
}

.feature-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.feature-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ===== PROS & CONS ===== */
.pros-cons-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.pros-list, .cons-list {
  list-style: none;
}

.pros-list li, .cons-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 0;
  font-size: 14px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-color);
}

.pros-list li:last-child, .cons-list li:last-child {
  border-bottom: none;
}

.pros-list li::before {
  content: '✓';
  color: var(--accent-green);
  font-weight: 700;
  flex-shrink: 0;
}

.cons-list li::before {
  content: '✗';
  color: var(--accent-red);
  font-weight: 700;
  flex-shrink: 0;
}

/* ===== SCORES ===== */
.scores-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.score-row {
  display: flex;
  align-items: center;
  gap: 16px;
}

.score-label {
  font-size: 14px;
  color: var(--text-secondary);
  min-width: 80px;
}

.score-bar {
  flex: 1;
  height: 8px;
  background: var(--bg-tertiary);
  border-radius: 4px;
  overflow: hidden;
}

.score-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.6s ease;
}

.score-fill.high { background: linear-gradient(90deg, var(--accent-green), #7ee787); }
.score-fill.medium { background: linear-gradient(90deg, var(--accent-yellow), #ffd93d); }
.score-fill.low { background: linear-gradient(90deg, var(--accent-red), #ff6b6b); }

.score-value {
  font-size: 16px;
  font-weight: 700;
  min-width: 36px;
  text-align: right;
}

/* ===== QUOTE BOX ===== */
.quote-box {
  background: var(--bg-tertiary);
  border-left: 3px solid var(--accent-orange);
  padding: 20px 24px;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  font-style: italic;
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.7;
}

/* ===== CHANGELOG ===== */
.changelog-list {
  list-style: none;
}

.changelog-item {
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border-color);
}

.changelog-item:last-child {
  border-bottom: none;
}

.changelog-date {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
  min-width: 80px;
  font-family: var(--font-mono);
}

.changelog-content {
  flex: 1;
}

.changelog-version {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-orange);
  margin-bottom: 4px;
}

.changelog-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ===== RELATED PRODUCTS ===== */
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

.related-card {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  cursor: pointer;
  transition: var(--transition-fast);
  text-decoration: none;
  color: inherit;
}

.related-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
}

.related-logo {
  font-size: 32px;
  margin-bottom: 8px;
}

.related-name {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
}

.related-maker {
  font-size: 12px;
  color: var(--text-muted);
}

/* ===== SIDEBAR ===== */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: sticky;
  top: 80px;
}

.sidebar-section {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 16px;
}

.sidebar-section:hover {
  box-shadow: var(--shadow-sm);
}

.sidebar-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}

/* ===== PRICING CARD ===== */
.pricing-card {
  background: linear-gradient(135deg, rgba(46,213,115,0.1), rgba(46,213,115,0.05));
  border: 1px solid rgba(46,213,115,0.2);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
}

.pricing-card.free {
  background: linear-gradient(135deg, rgba(255,165,2,0.1), rgba(255,165,2,0.05));
  border-color: rgba(255,165,2,0.2);
}

.pricing-card.enterprise {
  background: linear-gradient(135deg, rgba(124,58,237,0.1), rgba(124,58,237,0.05));
  border-color: rgba(124,58,237,0.2);
}

.price-main {
  font-size: 28px;
  font-weight: 800;
  color: var(--accent-green);
  margin-bottom: 8px;
}

.pricing-card.free .price-main {
  color: var(--accent-yellow);
}

.pricing-card.enterprise .price-main {
  color: var(--accent-purple);
}

.price-note {
  font-size: 13px;
  color: var(--text-muted);
}

/* ===== SPECS LIST ===== */
.specs-list {
  list-style: none;
}

.spec-item {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-color);
  font-size: 14px;
}

.spec-item:last-child {
  border-bottom: none;
}

.spec-label {
  color: var(--text-muted);
}

.spec-value {
  color: var(--text-primary);
  font-weight: 500;
  text-align: right;
}

.spec-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.spec-tag {
  padding: 3px 8px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  font-size: 11px;
  color: var(--text-secondary);
}

/* ===== SUITABLE TAGS ===== */
.suitable-tags {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.suitable-tag {
  padding: 8px 16px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 100px;
  font-size: 13px;
  color: var(--text-secondary);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
  .content-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .sidebar {
    position: static;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

@media (max-width: 1024px) {
  .product-hero {
    grid-template-columns: auto 1fr auto;
    padding: 32px;
  }

  .product-actions {
    flex-direction: column;
  }
}

@media (max-width: 768px) {
  .product-detail-page {
    padding-top: 80px;
  }

  .product-hero {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 28px;
    gap: 24px;
  }

  .product-logo-large {
    margin: 0 auto;
    width: 80px;
    height: 80px;
    font-size: 40px;
  }

  .product-name {
    font-size: 28px;
  }

  .product-actions {
    flex-direction: row;
    justify-content: center;
    flex-wrap: wrap;
  }

  .sidebar {
    grid-template-columns: 1fr;
  }

  .pros-cons-grid {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 24px;
  }

  .btn {
    width: 100%;
  }

  .pros-cons-grid {
    grid-template-columns: 1fr;
  }

  .related-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .product-name {
    font-size: 28px;
  }

  .rating-card {
    margin: 0 auto;
  }
}

@media (max-width: 480px) {
  .related-grid {
    grid-template-columns: 1fr;
  }

  .changelog-item {
    flex-direction: column;
    gap: 8px;
  }

  .changelog-date {
    min-width: auto;
  }

  .score-label {
    min-width: 60px;
    font-size: 12px;
  }
}
