/* Sticky Compare Bar */
.compare-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #1e281f;
  color: #fff;
  z-index: 99999;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.15);
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.compare-bar.is-visible {
  transform: translateY(0);
}
.compare-bar.is-collapsed {
  transform: translateY(calc(100% - 48px));
}
.compare-bar-inner {
  display: flex;
  align-items: center;
  max-width: 1300px;
  margin: 0 auto;
  padding: 10px 24px;
  gap: 20px;
}
.compare-bar-toggle {
  background: transparent;
  border: none;
  color: #fff;
  cursor: pointer;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
}
.compare-count {
  background: #3b533d;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 12px;
  transition: transform 0.2s ease;
}
.compare-count.is-bumped {
  transform: scale(1.3);
}
.compare-bar-slots {
  display: flex;
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 1;
}
.compare-bar-slot {
  background: rgba(255,255,255,0.07);
  border-radius: 6px;
  padding: 6px 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  max-width: 240px;
  position: relative;
}
.compare-bar-slot.is-empty {
  border: 1px dashed rgba(255,255,255,0.2);
  justify-content: center;
  color: rgba(255,255,255,0.4);
  font-size: 13px;
}
.compare-bar-product {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: #fff;
  overflow: hidden;
  flex: 1;
}
.compare-bar-thumb {
  width: 32px;
  height: 32px;
  background: #fff;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}
.compare-bar-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.compare-bar-name {
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.compare-bar-remove {
  background: none;
  border: none;
  color: rgba(255,255,255,0.6);
  cursor: pointer;
  font-size: 16px;
  padding: 0 4px;
}
.compare-bar-remove:hover {
  color: #fff;
}
.compare-bar-remove::after {
  content: '×';
}
.compare-bar-go {
  background: #3b533d;
  color: #fff;
  padding: 10px 20px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  white-space: nowrap;
  transition: background 0.2s;
}
.compare-bar-go:hover {
  background: #4b684e;
}
.compare-bar-go[aria-disabled="true"] {
  background: rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.4);
  pointer-events: none;
}
.compare-bar-clear {
  background: none;
  border: none;
  color: rgba(255,255,255,0.6);
  cursor: pointer;
  font-size: 13px;
  text-decoration: underline;
}
.compare-bar-notice {
  position: absolute;
  top: -32px;
  left: 24px;
  background: #2b3d2c;
  color: #fff;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 12px;
}

/* Compare Matrix Page Table */
.compare-page-container {
  max-width: 1300px;
  margin: 40px auto;
  padding: 0 20px;
}
.compare-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
}
.compare-table-scroll {
  overflow-x: auto;
}
.compare-matrix-table {
  width: 100%;
  border-collapse: collapse;
  background: #f9f8f6;
  border: 1px solid #e5e2db;
}
.compare-matrix-table th, .compare-matrix-table td {
  padding: 16px;
  border: 1px solid #e5e2db;
  text-align: left;
  vertical-align: top;
  font-size: 14px;
}
.spec-label-col, .spec-label {
  font-weight: 600;
  width: 200px;
  background: #f2efe9;
  color: #2c352d;
}
.compare-product-col {
  width: calc(80% / 3);
  background: #fff;
}
.compare-col-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
}
.compare-col-thumb {
  width: 120px;
  height: 120px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.compare-col-thumb img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.compare-col-inner h3 {
  font-size: 16px;
  margin: 0 0 12px 0;
  color: #1e281f;
}
.compare-col-actions {
  display: flex;
  gap: 8px;
  margin-top: auto;
}
.btn-view, .btn-remove-action {
  padding: 6px 14px;
  border-radius: 4px;
  font-size: 13px;
  text-decoration: none;
  cursor: pointer;
}
.btn-view {
  background: #1e281f;
  color: #fff;
}
.btn-remove-action {
  background: #d9534f;
  color: #fff;
  border: none;
}
.compare-col-remove {
  position: absolute;
  top: -10px;
  right: -10px;
  background: #ccc;
  border: none;
  border-align: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  cursor: pointer;
  font-weight: bold;
}