/* =========================================================
   UZISELLER PRODUCT MARKETPLACE
   AppMMO-Inspired Clear Category Layout + Dark Tech Theme
   ========================================================= */

.uz-ai-store {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* Loading State */
.uz-loading {
  text-align: center;
  padding: 80px 20px;
}

.uz-spinner {
  width: 48px;
  height: 48px;
  border: 4px solid rgba(124, 77, 255, 0.2);
  border-top-color: #7c4dff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 20px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.uz-loading p {
  color: #aaa5c2;
  font-size: 15px;
}

.uz-api-warning {
  background: rgba(255, 193, 7, 0.1);
  border: 1px solid rgba(255, 193, 7, 0.3);
  border-radius: 8px;
  padding: 12px 20px;
  text-align: center;
  margin-bottom: 20px;
}

.uz-api-warning small {
  color: #ffc107;
  font-size: 13px;
}

.uz-api-warning p {
  color: #c8c0df;
}

.uz-sub-checkout {
  position: relative;
  width: min(520px, calc(100vw - 24px));
  color: #f3efff;
  border: 1px solid rgba(171, 137, 255, .3);
  border-radius: 16px;
  background: #171329;
  box-shadow: 0 28px 90px rgba(0, 0, 0, .6), 0 0 45px rgba(124, 77, 255, .16);
}

.order-modal-overlay.uz-sub-checkout-overlay {
  z-index: 10000;
}

.uz-sub-checkout h3 {
  color: #fff;
  font-size: 22px;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.uz-sub-checkout .smm-review-meta {
  color: #aaa5c2;
  font-size: 13px;
}

.uz-sub-checkout-close {
  position: absolute;
  top: 12px;
  right: 14px;
  border: 0;
  background: transparent;
  color: #c8bafa;
  font-size: 28px;
  cursor: pointer;
}

.uz-sub-checkout .smm-review-customer,
.uz-sub-checkout-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.uz-sub-checkout label span {
  display: block;
  color: #c8c0df;
  font-size: 12px;
  font-weight: 600;
}

.uz-sub-checkout input {
  box-sizing: border-box;
  width: 100%;
  height: 42px;
  margin-top: 6px;
  padding: 0 11px;
  border: 1px solid rgba(196, 179, 255, .22);
  border-radius: 8px;
  outline: 0;
  background: rgba(255, 255, 255, .05);
  color: #fff;
  font: inherit;
}

.uz-sub-checkout input:focus {
  border-color: #a987ff;
  box-shadow: 0 0 0 3px rgba(124, 77, 255, .18);
}

.uz-sub-checkout .smm-review-footer {
  align-items: flex-end;
  margin-top: 18px;
}

.uz-sub-checkout .smm-review-footer small {
  max-width: 220px;
  color: #aaa5c2;
  font-size: 11px;
  line-height: 1.5;
}

.uz-sub-checkout .smm-review-footer strong {
  color: #c4a8ff;
}

.uz-sub-checkout .smm-review-footer .btn {
  min-height: 42px;
  border-radius: 8px;
  background: linear-gradient(135deg, #8053ed, #5b39bc);
  color: #fff;
  font-size: 13px;
}

.uz-sub-checkout .smm-review-footer .btn:disabled {
  cursor: wait;
  opacity: .65;
}

.uz-sub-checkout-error {
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 107, 126, .3);
  border-radius: 8px;
  background: rgba(255, 70, 95, .1);
  color: #ff9aaa;
  font-size: 13px;
}

/* Store Header */
.uz-store-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  flex-wrap: wrap;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.uz-store-title {
  flex: 1;
  min-width: 300px;
}

.uz-kicker {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: #55c9ff;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.uz-store-title h2 {
  font-size: 32px;
  font-weight: 800;
  margin: 0 0 10px;
  color: #fff;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.uz-store-title p {
  color: #aaa5c2;
  margin: 0;
  font-size: 15px;
  line-height: 1.5;
}

.uz-search-box {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  padding: 12px 20px;
  min-width: 300px;
  transition: all 0.2s ease;
}

.uz-search-box:focus-within {
  border-color: #7c4dff;
  background: rgba(124, 77, 255, 0.08);
  box-shadow: 0 0 0 3px rgba(124, 77, 255, 0.1);
}

.uz-search-box svg {
  color: #aaa5c2;
  flex-shrink: 0;
}

.uz-search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: #fff;
  font-size: 14px;
  width: 100%;
}

.uz-search-box input::placeholder {
  color: #666;
}

/* Trust Section (moved to top) */
.uz-trust-section {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  padding: 24px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
}

.uz-trust-top {
  background: linear-gradient(135deg, rgba(124, 77, 255, 0.05) 0%, rgba(85, 201, 255, 0.05) 100%);
  border-color: rgba(124, 77, 255, 0.15);
}

.uz-trust-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.uz-trust-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(85, 201, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.uz-trust-item strong {
  display: block;
  font-size: 15px;
  color: #fff;
  margin-bottom: 4px;
  font-weight: 700;
}

.uz-trust-item p {
  font-size: 13px;
  color: #888;
  margin: 0;
  line-height: 1.5;
}

/* Brand Category Cards (AppMMO-style) */
.uz-brand-categories {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 24px;
}

.uz-category-card {
  border: 2px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  padding: 28px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.uz-category-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.uz-category-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.uz-catalog-categories {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(138px, 1fr));
  gap: 7px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 14px;
  background: rgba(8, 8, 17, .72);
}

.uz-category-chip {
  display: flex;
  min-width: 0;
  min-height: 38px;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 7px;
  background: linear-gradient(180deg, #292a32, #202128);
  color: #e8e6f1;
  font-size: 12px;
  font-weight: 650;
  text-align: left;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, transform .16s ease;
}

.uz-category-chip .uz-category-icon {
  flex: 0 0 auto;
  color: #75cfff;
  font-size: 14px;
}

.uz-category-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.uz-category-chip:hover {
  transform: translateY(-1px);
  border-color: rgba(115, 157, 255, .45);
  background: #30313c;
}

.uz-category-chip.active {
  border-color: transparent;
  background: linear-gradient(110deg, #6249e8, #39aee7);
  color: #fff;
  box-shadow: 0 4px 14px rgba(71, 111, 230, .25);
}

.uz-category-chip.active > span {
  color: #fff;
}

.uz-category-chip small {
  flex: 0 0 auto;
  margin-left: auto;
  color: rgba(255, 255, 255, .67);
  font-size: 10px;
  font-weight: 600;
}

.uz-category-chip.active small {
  color: rgba(255, 255, 255, .86);
}

/* ChatGPT Brand Styling */
.chatgpt-card {
  border-color: rgba(16, 163, 127, 0.3);
}

.chatgpt-card::before {
  background: linear-gradient(90deg, #10a37f, #1aa587);
}

.chatgpt-card:hover,
.chatgpt-card.expanded {
  border-color: #10a37f;
  background: linear-gradient(135deg, rgba(16, 163, 127, 0.12) 0%, rgba(10, 10, 32, 0.8) 100%);
}

.chatgpt-card:hover::before,
.chatgpt-card.expanded::before {
  opacity: 1;
}

.chatgpt-icon {
  color: #10a37f;
  background: rgba(16, 163, 127, 0.15);
}

.ai-card {
  border-color: rgba(133, 102, 255, .34);
}

.ai-card::before {
  background: linear-gradient(90deg, #8061ff, #32c5ff);
}

.ai-card:hover,
.ai-card.expanded {
  border-color: #947aff;
  background: linear-gradient(135deg, rgba(108, 76, 220, .14), rgba(10, 10, 32, .8));
}

.ai-card:hover::before,
.ai-card.expanded::before {
  opacity: 1;
}

.ai-icon {
  color: #a992ff;
  background: rgba(124, 77, 255, .16);
}

/* Claude Brand Styling */
.claude-card {
  border-color: rgba(204, 121, 74, 0.3);
}

.claude-card::before {
  background: linear-gradient(90deg, #cc794a, #d98a5e);
}

.claude-card:hover,
.claude-card.expanded {
  border-color: #cc794a;
  background: linear-gradient(135deg, rgba(204, 121, 74, 0.12) 0%, rgba(10, 10, 32, 0.8) 100%);
}

.claude-card:hover::before,
.claude-card.expanded::before {
  opacity: 1;
}

.claude-icon {
  color: #cc794a;
  background: rgba(204, 121, 74, 0.15);
}

/* Category Card Layout */
.uz-cat-header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 20px;
}

.uz-cat-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.uz-cat-info {
  flex: 1;
  min-width: 0;
}

.uz-cat-info h3 {
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  margin: 0 0 6px;
  letter-spacing: -0.01em;
}

.uz-cat-info p {
  font-size: 14px;
  color: #aaa5c2;
  margin: 0 0 12px;
  line-height: 1.5;
}

.uz-cat-meta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.uz-badge {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
}

.uz-price-tag {
  font-size: 13px;
  font-weight: 700;
  color: #55c9ff;
}

.uz-expand-btn {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.uz-expand-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: scale(1.1);
}

.uz-cat-features {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.uz-cat-features span {
  font-size: 13px;
  color: #aaa5c2;
  line-height: 1.4;
}

/* Expanded Products Area */
.uz-products-area {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  padding: 32px;
  transition: all 0.4s ease;
}

.uz-products-area.hidden {
  display: none;
}

.uz-products-area.visible {
  display: block;
  animation: slideDown 0.4s ease;
}

.uz-products-area.visible {
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 14px;
  background: rgba(255, 255, 255, .018);
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.uz-products-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  flex-wrap: wrap;
  gap: 16px;
}

.uz-products-header h3 {
  font-size: 24px;
  font-weight: 800;
  color: #fff;
  margin: 0;
}

.uz-products-controls {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

.uz-sort-buttons {
  display: flex;
  gap: 8px;
  background: rgba(255, 255, 255, 0.03);
  padding: 4px;
  border-radius: 10px;
}

.uz-sort-btn {
  padding: 8px 16px;
  background: transparent;
  border: none;
  border-radius: 8px;
  color: #aaa5c2;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.uz-sort-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

.uz-sort-btn.active {
  background: rgba(124, 77, 255, 0.2);
  color: #fff;
}

.uz-close-btn {
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #fff;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.uz-close-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: scale(1.05);
}

/* Product Grid */
.uz-product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.uz-load-more-wrap {
  display: flex;
  justify-content: center;
  padding: 22px 0 4px;
}

.uz-load-more {
  min-height: 42px;
  padding: 0 22px;
  border: 1px solid rgba(124, 124, 255, .35);
  border-radius: 9px;
  background: rgba(124, 77, 255, .12);
  color: #e7ddff;
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}

.uz-load-more:hover {
  background: rgba(124, 77, 255, .24);
}

.uz-results-count {
  margin: 0;
  color: #918ba7;
  font-size: 12px;
}

.uz-translation-notice:not([hidden]) {
  margin: -8px 0 14px;
  color: #d9c38a;
  font-size: 12px;
}

.uz-product-card {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.02) 100%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 20px;
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.uz-product-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.uz-product-card.chatgpt-product::before {
  background: #10a37f;
}

.uz-product-card.claude-product::before {
  background: #cc794a;
}

.uz-product-card.ai-product::before {
  background: linear-gradient(180deg, #8061ff, #32c5ff);
}

.uz-product-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.uz-product-card:hover::before {
  opacity: 1;
}

.uz-prod-badges {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  min-height: 24px;
}

.uz-popular-badge {
  display: inline-block;
  padding: 4px 10px;
  background: linear-gradient(135deg, rgba(255, 107, 0, 0.2), rgba(255, 193, 7, 0.2));
  border: 1px solid rgba(255, 193, 7, 0.3);
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  color: #ffc107;
}

.uz-stock-badge {
  display: inline-block;
  padding: 4px 10px;
  background: rgba(76, 175, 80, 0.15);
  border: 1px solid rgba(76, 175, 80, 0.3);
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  color: #4caf50;
}

.uz-prod-header {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
}

.uz-prod-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  object-fit: cover;
  flex-shrink: 0;
}

.uz-prod-icon-placeholder {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.uz-prod-icon-placeholder.chatgpt-icon {
  background: rgba(16, 163, 127, 0.15);
}

.uz-prod-icon-placeholder.claude-icon {
  background: rgba(204, 121, 74, 0.15);
}

.uz-prod-icon-placeholder.ai-icon {
  background: rgba(124, 77, 255, .16);
}

.uz-prod-info {
  flex: 1;
  min-width: 0;
}

.uz-prod-info h4 {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 6px;
  line-height: 1.3;
}

.uz-prod-info p {
  font-size: 13px;
  color: #888;
  margin: 0;
  line-height: 1.4;
}

.uz-prod-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.uz-prod-price {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.uz-price-label {
  font-size: 11px;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.uz-prod-price strong {
  font-size: 20px;
  font-weight: 800;
  color: #55c9ff;
}

.uz-buy-btn {
  padding: 10px 20px;
  background: linear-gradient(135deg, #7c4dff, #6a3de8);
  border: none;
  border-radius: 8px;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.uz-buy-btn:hover {
  background: linear-gradient(135deg, #8a5cff, #7a4df8);
  transform: scale(1.05);
  box-shadow: 0 4px 16px rgba(124, 77, 255, 0.4);
}

.uz-buy-btn.chatgpt-btn {
  background: linear-gradient(135deg, #10a37f, #0d8a6a);
}

.uz-buy-btn.chatgpt-btn:hover {
  background: linear-gradient(135deg, #1aa587, #10a37f);
  box-shadow: 0 4px 16px rgba(16, 163, 127, 0.4);
}

.uz-buy-btn.claude-btn {
  background: linear-gradient(135deg, #cc794a, #b8663d);
}

.uz-buy-btn.claude-btn:hover {
  background: linear-gradient(135deg, #d98a5e, #cc794a);
  box-shadow: 0 4px 16px rgba(204, 121, 74, 0.4);
}

.uz-buy-btn.ai-btn {
  background: linear-gradient(135deg, #8053ed, #368ce6);
}

.uz-buy-btn.ai-btn:hover {
  background: linear-gradient(135deg, #946fff, #4aa8ff);
  box-shadow: 0 4px 16px rgba(105, 101, 255, .4);
}

/* Empty State */
.uz-empty {
  text-align: center;
  padding: 60px 20px;
  color: #666;
}

.uz-empty-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.uz-empty p {
  font-size: 15px;
  margin: 0 0 16px;
}

/* Responsive */
@media (max-width: 768px) {
  .uz-catalog-categories {
    grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
    gap: 6px;
    padding: 10px;
  }

  .uz-category-chip {
    min-height: 36px;
    padding: 6px 8px;
    font-size: 11px;
  }

  .uz-products-area.visible {
    padding: 14px;
  }

  .uz-sub-checkout .smm-review-customer,
  .uz-sub-checkout-options {
    grid-template-columns: 1fr;
  }

  .uz-sub-checkout .smm-review-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .uz-sub-checkout .smm-review-footer .btn {
    width: 100%;
  }

  .uz-store-header {
    flex-direction: column;
    align-items: stretch;
  }

  .uz-search-box {
    min-width: auto;
  }

  .uz-brand-categories {
    grid-template-columns: 1fr;
  }

  .uz-store-title h2 {
    font-size: 24px;
  }

  .uz-product-grid {
    grid-template-columns: 1fr;
  }

  .uz-products-area {
    padding: 20px;
  }

  .uz-products-header {
    flex-direction: column;
    align-items: stretch;
  }

  .uz-products-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .uz-sort-buttons {
    justify-content: center;
  }

  .uz-trust-section {
    grid-template-columns: 1fr;
    padding: 20px;
  }

  .uz-cat-header {
    flex-wrap: wrap;
  }

  .uz-prod-footer {
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
  }

  .uz-buy-btn {
    width: 100%;
  }
}
