/* ==========================================================================
   TikOyun Web Theme - Interactive Components & Widgets
   ========================================================================== */

/* --- Feature Cards --- */
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 2.2rem 1.8rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.feature-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(34, 211, 210, 0.4);
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

.feature-icon-wrapper {
  width: 54px;
  height: 54px;
  border-radius: 12px;
  background: rgba(34, 211, 210, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-size: 1.6rem;
  margin-bottom: 1.4rem;
  border: 1px solid rgba(34, 211, 210, 0.2);
}

.feature-card h4 {
  font-family: var(--font-display);
  font-size: 1.22rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.8rem;
}

.feature-card p {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* --- Game Cards & Grid --- */
.game-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
  position: relative;
}

.game-card:hover {
  transform: translateY(-6px);
  border-color: rgba(124, 92, 255, 0.4);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.6);
}

.game-card-media {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #111116;
}

.game-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.game-card:hover .game-card-media img {
  transform: scale(1.05);
}

.game-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(124, 92, 255, 0.85);
  backdrop-filter: blur(8px);
  color: #fff;
  padding: 0.25rem 0.65rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  z-index: 2;
}

.game-badge.badge-web {
  background: rgba(34, 211, 210, 0.85);
  color: #0a0a0d;
}

.game-card-body {
  padding: 1.4rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.game-card-category {
  color: var(--primary);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.4rem;
}

.game-card-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.8rem;
  line-height: 1.3;
}

.game-card-desc {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.5;
  margin-bottom: 1.2rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.game-card-foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1rem;
  border-top: 1px solid var(--border-light);
}

.game-price {
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
}

.game-price span.period {
  font-size: 0.78rem;
  color: var(--text-dim);
  font-weight: 400;
}

/* Category Filter Tabs */
.filter-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 2.8rem;
}

.filter-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-light);
  color: var(--text-muted);
  padding: 0.55rem 1.25rem;
  border-radius: 20px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.filter-btn.active {
  background: var(--primary);
  color: #0a0a0d;
  border-color: var(--primary);
  box-shadow: 0 4px 14px var(--primary-glow);
}

/* --- Pricing Cards --- */
.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 2.4rem 2rem;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all 0.3s ease;
}

.pricing-card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 255, 255, 0.2);
}

.pricing-card.featured {
  background: linear-gradient(180deg, rgba(30, 24, 54, 0.9), rgba(18, 18, 26, 0.9));
  border: 2px solid var(--accent);
  box-shadow: 0 16px 40px rgba(124, 92, 255, 0.25);
}

.pricing-ribbon {
  position: absolute;
  top: -14px;
  right: 24px;
  background: linear-gradient(90deg, var(--accent), #c026d3);
  color: #fff;
  padding: 0.3rem 0.9rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.pricing-header h4 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.4rem;
}

.pricing-price {
  font-family: var(--font-display);
  font-size: 2.4rem;
  font-weight: 800;
  color: #fff;
  margin: 1rem 0 0.3rem;
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
}

.pricing-price span.period {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 400;
}

.pricing-note {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 1.8rem;
}

.pricing-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-bottom: 2.2rem;
  flex: 1;
}

.pricing-features li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.pricing-features li.excluded {
  color: var(--text-dim);
  text-decoration: line-through;
  opacity: 0.6;
}

.pricing-features li .icon-check {
  color: var(--primary);
  font-weight: 900;
  font-size: 0.95rem;
  margin-top: 2px;
}

.pricing-features li .icon-cross {
  color: var(--danger);
  font-weight: 900;
  font-size: 0.95rem;
  margin-top: 2px;
}

/* --- Interactive World Map & Marquee --- */
.world-map-wrapper {
  position: relative;
  max-width: 980px;
  margin: 0 auto;
}

.world-map-img {
  width: 100%;
  opacity: 0.35;
  filter: drop-shadow(0 0 20px rgba(34, 211, 210, 0.2));
}

.map-hotspot {
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--primary);
  transform: translate(-50%, -50%);
  cursor: pointer;
}

.map-hotspot::after {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid var(--primary);
  animation: pulse-ring 2s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.6); opacity: 1; }
  100% { transform: scale(2.2); opacity: 0; }
}

.hotspot-tooltip {
  position: absolute;
  bottom: 120%;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(14, 14, 18, 0.95);
  border: 1px solid var(--border-light);
  padding: 0.3rem 0.7rem;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.map-hotspot:hover .hotspot-tooltip {
  opacity: 1;
}

/* Country Marquee */
.marquee-container {
  overflow: hidden;
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.02);
  border-block: 1px solid var(--border-light);
  padding: 0.85rem 0;
  margin-top: 2rem;
}

.marquee-content {
  display: inline-flex;
  gap: 2.5rem;
  animation: marquee-scroll 25s linear infinite;
}

.marquee-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-muted);
}

.marquee-dot {
  width: 6px;
  height: 6px;
  background: var(--primary);
  border-radius: 50%;
}

@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* --- FAQ Accordion --- */
.faq-accordion {
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: border-color 0.25s ease;
}

.faq-item.active {
  border-color: rgba(34, 211, 210, 0.5);
}

.faq-header {
  padding: 1.2rem 1.6rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
}

.faq-header h4 {
  font-size: 1.05rem;
  font-weight: 600;
  color: #fff;
}

.faq-icon {
  font-size: 1.2rem;
  color: var(--primary);
  transition: transform 0.3s ease;
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
}

.faq-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.35s ease;
  padding: 0 1.6rem;
}

.faq-item.active .faq-content {
  max-height: 250px;
  padding: 0 1.6rem 1.4rem;
}

.faq-content p {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* --- Gift Interactions Table (Game Detail) --- */
.table-responsive {
  overflow-x: auto;
  margin: 1.8rem 0;
}

.gifts-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.gifts-table th,
.gifts-table td {
  padding: 1rem 1.25rem;
  text-align: left;
  border-bottom: 1px solid var(--border-light);
}

.gifts-table th {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-main);
  font-size: 0.88rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.gifts-table td {
  color: var(--text-muted);
  font-size: 0.92rem;
}

.gifts-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.action-badge {
  display: inline-block;
  padding: 0.25rem 0.65rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.badge-event { background: rgba(34, 211, 210, 0.15); color: var(--primary); }
.badge-hazard { background: rgba(239, 68, 68, 0.15); color: var(--danger); }
.badge-helper { background: rgba(34, 197, 94, 0.15); color: var(--success); }
.badge-upgrade { background: rgba(251, 191, 36, 0.15); color: var(--gold); }
.badge-bonus { background: rgba(124, 92, 255, 0.15); color: var(--accent); }

/* --- WhatsApp / Live Chat Widget --- */
.chat-widget-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
  cursor: pointer;
  z-index: 9999;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.chat-widget-btn:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 26px rgba(37, 211, 102, 0.6);
}

.chat-widget-btn svg {
  width: 32px;
  height: 32px;
  fill: currentColor;
}

.chat-popup {
  position: fixed;
  bottom: 96px;
  right: 24px;
  width: 340px;
  background: #111116;
  border: 1px solid var(--border-light);
  border-radius: 16px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.7);
  overflow: hidden;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  opacity: 0;
  transform: translateY(20px) scale(0.95);
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.chat-popup.open {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.chat-header {
  background: #075e54;
  padding: 1rem 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.9rem;
  color: #fff;
}

.chat-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #0a0a0d;
  font-weight: 800;
}

.chat-info h5 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 2px;
}

.chat-info span {
  font-size: 0.75rem;
  opacity: 0.85;
}

.chat-close {
  margin-left: auto;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.4rem;
  cursor: pointer;
  opacity: 0.8;
}

.chat-close:hover {
  opacity: 1;
}

.chat-body {
  padding: 1.2rem;
  max-height: 280px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  background: #0a0a0e;
}

.chat-bubble {
  max-width: 82%;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  font-size: 0.88rem;
  line-height: 1.4;
}

.chat-bubble.received {
  background: #1f1f2a;
  color: #f1f1f4;
  align-self: flex-start;
  border-bottom-left-radius: 2px;
}

.chat-footer {
  padding: 0.8rem 1rem;
  background: #14141c;
  display: flex;
  gap: 0.6rem;
  border-top: 1px solid var(--border-light);
}

.chat-input {
  flex: 1;
  background: #0a0a0d;
  border: 1px solid var(--border-light);
  border-radius: 20px;
  padding: 0.55rem 1rem;
  color: #fff;
  font-size: 0.85rem;
  outline: none;
}

.chat-input:focus {
  border-color: var(--primary);
}

.chat-send-btn {
  background: #25d366;
  border: none;
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* --- Auth Forms & Modals --- */
.auth-box {
  max-width: 460px;
  margin: 3rem auto;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 2.8rem 2.4rem;
}

.auth-header {
  text-align: center;
  margin-bottom: 2rem;
}

.auth-header h3 {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.5rem;
}

.auth-header p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.form-group {
  margin-bottom: 1.3rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #e2e8f0;
}

.input-control {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  color: #fff;
  font-size: 0.92rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.tiktok-field-group {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  position: relative;
}

.tiktok-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  flex: 1;
}

.tiktok-prefix {
  position: absolute;
  left: 14px;
  color: var(--text-dim);
  font-weight: 700;
  pointer-events: none;
  z-index: 2;
}

.tiktok-input-wrapper input {
  padding-left: 2rem;
  padding-right: 2.2rem;
  width: 100%;
}

.tiktok-spinner {
  position: absolute;
  right: 12px;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: tiktokSpin 0.65s linear infinite;
  pointer-events: none;
}

.tiktok-avatar-preview-wrap {
  width: 46px;
  height: 46px;
  min-width: 46px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  background: var(--surface-light);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
  cursor: pointer;
}

.tiktok-avatar-preview-wrap.loading {
  border-color: var(--primary);
  box-shadow: 0 0 12px var(--primary-glow);
  transform: scale(1.05);
}

.tiktok-avatar-preview-wrap.found {
  border-color: #22d3d2;
  box-shadow: 0 0 14px rgba(34, 211, 210, 0.6);
  animation: popAvatar 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.tiktok-avatar-preview-wrap.not-found {
  border-color: #ef4444;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.4);
}

.tiktok-avatar-preview {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 50%;
}

.tiktok-avatar-placeholder {
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.03);
}

.tiktok-avatar-badge {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 16px;
  height: 16px;
  background: #22c55e;
  border: 2px solid var(--bg-dark);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  color: #fff;
  font-weight: 800;
}

@keyframes popAvatar {
  0% { transform: scale(0.6); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

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

.field-status {
  font-size: 0.78rem;
  margin-top: 0.35rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 1.1rem;
}

.field-status.success { color: var(--success); }
.field-status.error { color: var(--danger); }
.field-status.info { color: var(--primary); }


/* --- Dynamic Catalog Controls & Modal --- */
.catalog-controls-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.search-box-wrapper {
  position: relative;
  flex: 1;
  min-width: 260px;
}

.search-box-wrapper input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 24px;
  padding: 0.7rem 1.2rem 0.7rem 2.8rem;
  color: #fff;
  font-size: 0.92rem;
  outline: none;
  transition: all 0.25s ease;
}

.search-box-wrapper input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.search-box-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-dim);
  font-size: 1rem;
  pointer-events: none;
}

.sort-select-wrapper select {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 20px;
  padding: 0.65rem 1.4rem;
  color: #fff;
  font-size: 0.88rem;
  font-weight: 600;
  outline: none;
  cursor: pointer;
}

.sort-select-wrapper select:focus {
  border-color: var(--primary);
}

.category-badge-pill {
  font-size: 0.72rem;
  background: rgba(255, 255, 255, 0.12);
  padding: 2px 7px;
  border-radius: 12px;
  margin-left: 6px;
}

.filter-btn.active .category-badge-pill {
  background: rgba(10, 10, 13, 0.25);
  color: #0a0a0d;
}

/* Modal Overlay */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 10, 13, 0.88);
  backdrop-filter: blur(12px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  background: #14141c;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  max-width: 820px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8);
  position: relative;
  transform: scale(0.95);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.open .modal-card {
  transform: scale(1);
}

.modal-close-btn {
  position: absolute;
  top: 18px;
  right: 20px;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  transition: background 0.2s ease;
}

.modal-close-btn:hover {
  background: rgba(255, 255, 255, 0.18);
}
