/* ============================================================================
   FLAME STORE - COMPONENTS
   جميع مكونات واجهة المستخدم
   ============================================================================ */

/* ============= BUTTONS ============= */
.btn {
  padding: 0.875rem 2rem;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--accent-primary);
  color: white;
  box-shadow: 0 4px 12px rgba(255, 46, 99, 0.3);
}

.btn-primary:hover {
  background: #e02555;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 46, 99, 0.4);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 2px solid var(--border-default);
}

.btn-secondary:hover {
  border-color: var(--accent-primary);
  background: rgba(255, 46, 99, 0.1);
  transform: translateY(-2px);
}

.btn-register {
  background: transparent;
  color: var(--text-primary);
  border: 2px solid var(--border-default);
  padding: 10px 14px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.btn-register svg {
  fill: var(--text-primary);
  transition: fill 0.3s;
}

.btn-register:hover {
  background: var(--bg-elevated);
  border-color: var(--accent-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(255, 46, 99, 0.15);
}

.btn-register:hover svg {
  fill: var(--accent-primary);
}

/* Back Button */
.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #4A5568;
  color: #FFFFFF;
  padding: 12px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  margin-bottom: 2rem;
  transition: all 0.3s;
  border: 2px solid #4A5568;
  font-size: 15px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.back-btn:hover {
  background: #5A6778;
  border-color: #5A6778;
  color: white;
  transform: translateX(-4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Back to Top Button */
.back-to-top {
  position: fixed;
  bottom: 30px;
  left: 30px;
  width: 50px;
  height: 50px;
  background: var(--accent-primary);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(255, 46, 99, 0.4);
  transition: all 0.3s ease;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top svg {
  fill: white;
}

.back-to-top:hover {
  background: #e02555;
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(255, 46, 99, 0.6);
}

.back-to-top:active {
  transform: translateY(0);
}

/* Social Links */
.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--bg-secondary);
  border: 2px solid var(--border-default);
  border-radius: 8px;
  transition: all 0.3s;
  text-decoration: none;
}

.social-link svg {
  fill: var(--text-primary);
  transition: fill 0.3s;
}

.social-link:hover {
  background: var(--bg-elevated);
  border-color: var(--accent-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(255, 46, 99, 0.15);
}

.social-link:hover svg {
  fill: var(--accent-primary);
}

/* ============= CATEGORY LINKS ============= */
.categoryLinks { 
  display: flex; 
  flex-wrap: wrap; 
  gap: 12px; 
  justify-content: center; 
  margin: 28px auto; 
  max-width: 1100px;
  padding: 0 1rem;
}

.categoryLinks .link { 
  display: flex;
  align-items: center;
  justify-content: center;
  width: 68px; 
  height: 68px; 
  background: linear-gradient(135deg, #373E47 0%, #2D333B 100%);
  border: 2px solid #545D68;
  border-radius: 14px; 
  position: relative; 
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.categoryLinks .link img { 
  width: 38px; 
  height: 38px; 
  object-fit: contain;
  transition: transform 0.3s ease;
  filter: brightness(1.2);
}

.categoryLinks .link:hover { 
  transform: translateY(-5px) scale(1.05);
  border-color: var(--accent-primary);
  box-shadow: 0 8px 24px rgba(255, 46, 99, 0.3);
  background: linear-gradient(135deg, var(--accent-primary) 0%, #E6294B 100%);
}

.categoryLinks .link:hover img {
  transform: scale(1.15);
  filter: brightness(1.3) drop-shadow(0 2px 8px rgba(255,255,255,0.3));
}

.categoryLinks .link:hover::after {
  content: attr(data-label);
  position: absolute;
  top: -40px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #2D333B 0%, #24292F 100%);
  color: white;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
  z-index: 10;
  border: 2px solid var(--accent-primary);
}

.categoryLinks .link.active { 
  border-color: var(--accent-primary);
  background: linear-gradient(135deg, var(--accent-primary) 0%, #E6294B 100%);
  box-shadow: 0 6px 20px rgba(230, 57, 70, 0.4);
  transform: scale(1.05);
}

.categoryLinks .link.active img {
  transform: scale(1.1);
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

/* Locked Categories */
.categoryLinks .link.locked {
  cursor: not-allowed;
  opacity: 0.5;
  border-color: #3a3f47;
  background: linear-gradient(135deg, #2a2f37 0%, #22272e 100%);
  user-select: none;
  -webkit-user-select: none;
}

.categoryLinks .link.locked:hover {
  transform: none;
  border-color: #3a3f47;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  background: linear-gradient(135deg, #2a2f37 0%, #22272e 100%);
}

.categoryLinks .link.locked:hover img {
  transform: none;
  filter: brightness(0.7) grayscale(0.5);
}

.categoryLinks .link.locked img {
  filter: brightness(0.7) grayscale(0.5);
  transition: none;
}

.categoryLinks .link.locked .lock-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.45);
  border-radius: 12px;
  z-index: 2;
}

.categoryLinks .link.locked .lock-icon {
  width: 20px;
  height: 20px;
  color: rgba(255, 255, 255, 0.8);
  filter: drop-shadow(0 1px 3px rgba(0,0,0,0.5));
}

.categoryLinks .link.locked:hover::after {
  content: attr(data-label) " 🔒";
  position: absolute;
  top: -40px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #2D333B 0%, #24292F 100%);
  color: #ff6b6b;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
  z-index: 10;
  border: 2px solid #ff6b6b;
}

/* ============= ACCOUNT CARDS ============= */
.accounts-container {
  max-width: 920px;
  margin: 0 auto;
  padding: 0 1rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.account-card {
  background: #1a1d21;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.2s ease;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  display: block;
  border: 1px solid #2d3339;
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

.account-card:hover {
  transform: translateY(-3px);
  border-color: #ff2e63;
  box-shadow: 0 12px 32px rgba(255, 46, 99, 0.2);
}

/* === Card Header === */
.card-header {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  gap: 14px;
  background: linear-gradient(135deg, #1f2328 0%, #1a1d21 100%);
  border-bottom: 1px solid #2d3339;
}

.card-icon-wrap {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, #282d33 0%, #1f2328 100%);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid #3d444d;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.card-icon-wrap img {
  width: 24px;
  height: 24px;
  object-fit: contain;
  filter: brightness(1.15);
}

.card-title {
  flex: 1;
  font-size: 16px;
  font-weight: 700;
  color: #f0f0f0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-price {
  font-size: 18px;
  font-weight: 800;
  color: #4ade80;
  white-space: nowrap;
  text-shadow: 0 0 15px rgba(74, 222, 128, 0.4);
}

/* === Status Tags === */
.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 20px;
  background: #16191d;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.tag-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.tag-green,
.tag.tag-green {
  background: rgba(34, 197, 94, 0.15) !important;
  color: #4ade80 !important;
  border: 1px solid rgba(34, 197, 94, 0.5) !important;
}

.tag-green .tag-icon,
.tag.tag-green .tag-icon {
  fill: #4ade80 !important;
}

.tag-red,
.tag.tag-red {
  background: rgba(239, 68, 68, 0.15) !important;
  color: #f87171 !important;
  border: 1px solid rgba(239, 68, 68, 0.5) !important;
}

.tag-red .tag-icon,
.tag.tag-red .tag-icon {
  fill: #f87171 !important;
}

/* === Info Row === */
.card-info {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background: #13161a;
  font-size: 13px;
  color: #9ca3af;
  font-weight: 500;
  border-top: 1px solid #2d3339;
}

.card-info .sep {
  color: #4b5563;
  margin: 0 4px;
}

/* === Card Footer === */
.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  background: #111418;
  border-top: 1px solid #2d3339;
}

.time-ago {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #6b7280;
  font-weight: 500;
}

.time-ago svg {
  width: 14px;
  height: 14px;
  fill: #6b7280;
}

.buy-btn {
  padding: 10px 24px;
  background: linear-gradient(135deg, #4ade80 0%, #22c55e 100%);
  color: #052e16;
  font-size: 14px;
  font-weight: 700;
  border-radius: 8px;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

.account-card:hover .buy-btn {
  transform: scale(1.03);
  box-shadow: 0 6px 20px rgba(34, 197, 94, 0.45);
}

/* === Yellow Tag === */
.tag-yellow {
  background: rgba(234, 179, 8, 0.12);
  color: #fbbf24;
  border: 1px solid rgba(234, 179, 8, 0.3);
}

.tag-yellow .tag-icon {
  fill: #fbbf24;
}

.tag-gray,
.tag.tag-gray {
  background: rgba(107, 114, 128, 0.15) !important;
  color: #9ca3af !important;
  border: 1px solid rgba(107, 114, 128, 0.4) !important;
}

.tag-gray .tag-icon,
.tag.tag-gray .tag-icon {
  fill: #9ca3af !important;
}

/* === miHoYo Game Rows === */
.mihoyo-game-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 20px;
  background: #13161a;
  border-top: 1px solid #2d3339;
}

.mihoyo-game-icon {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
}

.mihoyo-game-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  flex: 1;
}

.mihoyo-game-tags .tag {
  padding: 5px 10px;
  font-size: 11px;
}

/* === Games Row (Steam) === */
.card-games {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background: #13161a;
  border-top: 1px solid #2d3339;
  flex-wrap: wrap;
}

.game-icon {
  width: 80px;
  height: 38px;
  border-radius: 4px;
  overflow: hidden;
  background: #1f2328;
  border: 1px solid #3d444d;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
  flex-shrink: 0;
}

.game-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.game-icon:hover {
  transform: scale(1.08);
  border-color: #ff2e63;
  z-index: 10;
}

.game-icon[title]:hover::after {
  content: attr(title);
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: #1a1d21;
  color: #fff;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 11px;
  white-space: nowrap;
  border: 1px solid #3d444d;
  z-index: 100;
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.games-more {
  font-size: 12px;
  color: #6b7280;
  margin-left: 4px;
}


/* === Mobile === */
@media (max-width: 640px) {
  .accounts-container { padding: 0 12px 2rem; gap: 10px; }
  .card-header { padding: 14px 16px; gap: 12px; }
  .card-icon-wrap { width: 36px; height: 36px; }
  .card-icon-wrap img { width: 20px; height: 20px; }
  .card-title { font-size: 14px; }
  .card-price { font-size: 16px; }
  .card-tags { padding: 12px 16px; gap: 6px; }
  .tag { padding: 6px 10px; font-size: 11px; border-radius: 6px; }
  .tag-icon { width: 12px; height: 12px; }
  .card-info { padding: 10px 16px; font-size: 12px; }
  .card-games { padding: 10px 16px; gap: 6px; }
  .game-icon { width: 65px; height: 30px; }
  .card-footer { padding: 12px 16px; }
  .time-ago { font-size: 12px; }
  .buy-btn { padding: 8px 18px; font-size: 13px; }
}

/* ============= PRODUCT HEADER (Account Details) ============= */
.product-header {
  background: linear-gradient(135deg, #373E47 0%, #2D333B 100%);
  border-radius: 12px;
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  display: flex;
  align-items: center;
  gap: 1.5rem;
  border: 1px solid #545D68;
}

.product-image {
  width: 80px;
  height: 80px;
  border-radius: 12px;
  object-fit: contain;
  background: linear-gradient(135deg, #1C2128 0%, #22272E 100%);
  padding: 12px;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.3);
  border: 1px solid #444C56;
  transition: transform 0.2s;
}

.product-image:hover {
  transform: scale(1.05);
}

.product-info {
  flex: 1;
}

.product-title {
  color: #FFFFFF;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.product-price-wrapper {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
}

.product-price {
  color: var(--accent-primary);
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -1px;
}

.price-label {
  color: var(--accent-primary);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ============= SECTIONS & CARDS ============= */
.section-title {
  color: var(--text-primary);
  font-size: 1.4rem;
  font-weight: 700;
  margin: 2rem 0 1rem;
  padding: 1rem 1.5rem;
  background: var(--bg-card);
  border: 2px solid var(--accent-primary);
  border-radius: 12px;
  text-align: center;
  display: block;
  width: 100%;
}

.section-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.summary-card {
  background: var(--bg-card);
  padding: 1.25rem;
  border-radius: 10px;
  border: 1px solid var(--border-default);
  text-align: center;
  transition: all 0.2s;
}

.summary-card:hover {
  border-color: var(--accent-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(255, 46, 99, 0.12);
}

.summary-number {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--accent-primary);
  line-height: 1;
  margin-bottom: 0.25rem;
}

.summary-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.account-info {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.account-info > div {
  background: var(--bg-card);
  padding: 1.25rem 1rem;
  border-radius: 8px;
  border: 1px solid var(--border-default);
  transition: all 0.2s;
}

.account-info > div:hover {
  border-color: var(--accent-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(255, 46, 99, 0.15);
}

.account-info strong {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: var(--accent-primary);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.65rem;
  font-weight: 700;
  opacity: 0.95;
}

.account-info div span {
  color: var(--text-primary);
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.4;
  display: block;
  text-align: center;
}

/* ============= ITEMS GRID (Skins, Emotes, etc.) ============= */
.items-section {
  margin-bottom: 1.5rem;
}

.items-section .section-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.vbucks-info {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 46, 99, 0.1);
  padding: 0.5rem 1rem;
  border-radius: 8px;
  border: 1px solid var(--accent-primary);
}

.vbucks-info img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.vbucks-info span {
  color: var(--accent-primary);
  font-size: 1.1rem;
  font-weight: 700;
}

.items-content {
  background: var(--bg-card);
  padding: 1.5rem;
  border-radius: 12px;
  border: 1px solid var(--border-default);
  margin-top: 1rem;
}

.items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 0.75rem;
}

.skin-box,
.pickaxe-box,
.dance-box,
.glider-box {
  background: var(--bg-card);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.75rem;
  transition: all 0.2s ease;
  border: 1px solid var(--border-default);
}

.skin-box:hover,
.pickaxe-box:hover,
.dance-box:hover,
.glider-box:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(255, 46, 99, 0.18);
  border-color: var(--accent-primary);
}

.skin-box img,
.pickaxe-box img,
.dance-box img,
.glider-box img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 0.5rem;
}

.skin-box p,
.pickaxe-box p,
.dance-box p,
.glider-box p {
  font-size: 0.75rem;
  color: var(--text-primary);
  text-align: center;
  margin: 0;
  font-weight: 600;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* ============= EMPTY STATE ============= */
.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  background: var(--bg-card);
  border-radius: 12px;
  border: 2px dashed var(--border-default);
  margin: 2rem 0;
}

.empty-state svg {
  width: 120px;
  height: 120px;
  margin-bottom: 1.5rem;
  opacity: 0.5;
}

.empty-state h3 {
  color: var(--text-primary);
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.empty-state p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* ============= PAGINATION ============= */
.pagination { 
  text-align: center; 
  margin: 2rem auto;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  position: relative;
  z-index: 50;
}

.page-btn {
  background: var(--accent-primary);
  color: white;
  padding: 10px 20px;
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.2s;
  font-weight: 600;
  font-size: 14px;
  border: none;
  box-shadow: 0 2px 8px rgba(230, 57, 70, 0.25);
}

.page-btn:hover { 
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(230, 57, 70, 0.35);
}

.current-page { 
  color: var(--text-primary);
  font-size: 15px;
  font-weight: 600;
}

.no-accounts {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--text-secondary);
  font-size: 16px;
  font-weight: 500;
}

/* ============= ERROR PAGE ============= */
.error-card {
  background: var(--bg-card);
  border-radius: 16px;
  padding: 3rem 2rem;
  text-align: center;
  max-width: 600px;
  width: 100%;
  border: 1px solid var(--border-default);
  box-shadow: 0 8px 32px rgba(0,0,0,0.2);
}

.error-icon {
  width: 120px;
  height: 120px;
  margin: 0 auto 2rem;
  background: linear-gradient(135deg, var(--accent-primary) 0%, #ff4d7d 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(255, 46, 99, 0.3);
}

.error-icon svg {
  width: 60px;
  height: 60px;
  fill: white;
}

.error-code {
  font-size: 4rem;
  font-weight: 800;
  color: var(--accent-primary);
  margin-bottom: 1rem;
  line-height: 1;
}

.error-title {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 1rem;
}

.error-message {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  line-height: 1.6;
}

.error-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}


