/* أنماط مخصصة وتجربة بصرية فريدة */
body {
  font-family: 'Readex Pro', 'Cairo', system-ui, -apple-system, sans-serif;
  user-select: none;
  -webkit-user-select: none;
  touch-action: manipulation;
}

/* بطاقات اللاعبين وتأثير الدور النشط */
.player-card {
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.player-card.active-turn {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(99, 102, 241, 0.15), 0 4px 6px -2px rgba(99, 102, 241, 0.05);
}

#player-card-x.active-turn {
  border-color: #F43F5E;
  background: linear-gradient(135deg, #FFFFFF 60%, #FFF1F2 100%);
}

#player-card-o.active-turn {
  border-color: #0284C7;
  background: linear-gradient(135deg, #FFFFFF 60%, #F0F9FF 100%);
}

/* حركة التمائم */
.player-card.active-turn .mascot-anim {
  animation: mascot-bounce 1.5s infinite ease-in-out;
}

@keyframes mascot-bounce {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-3px) rotate(2deg); }
}

/* خلايا لوحة XO */
.xo-cell {
  background: #FFFFFF;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  cursor: pointer;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.06), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  outline: none;
}

.xo-cell:hover:not(.claimed) {
  transform: scale(1.03);
  box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.18);
  border: 2px dashed #818CF8;
}

.xo-cell:active:not(.claimed) {
  transform: scale(0.96);
}

.xo-cell.claimed {
  cursor: default;
}

/* رمز X */
.symbol-x {
  color: #E11D48;
  font-weight: 900;
  font-size: 3.25rem;
  line-height: 1;
  text-shadow: 0 4px 12px rgba(225, 29, 72, 0.25);
  animation: pop-in 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* رمز O */
.symbol-o {
  color: #0284C7;
  font-weight: 900;
  font-size: 3.25rem;
  line-height: 1;
  text-shadow: 0 4px 12px rgba(2, 132, 199, 0.25);
  animation: pop-in 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes pop-in {
  0% { transform: scale(0) rotate(-45deg); opacity: 0; }
  70% { transform: scale(1.15) rotate(5deg); }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

/* بطاقة الكلمة داخل السؤال */
.word-chip {
  background: #FFFFFF;
  border-radius: 12px;
  padding: 8px 10px;
  border: 1px solid #E2E8F0;
  text-align: center;
  font-weight: 700;
  font-size: 0.85rem;
  color: #1E293B;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  animation: slide-up 0.25s ease-out;
}

@keyframes slide-up {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* أزرار الإجابات */
.option-btn {
  width: 100%;
  text-align: right;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1.5px solid #E2E8F0;
  background: #F8FAFC;
  color: #334155;
  font-weight: 600;
  font-size: 0.82rem;
  transition: all 0.15s ease;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.option-btn:hover:not(:disabled) {
  border-color: #6366F1;
  background: #EEF2FF;
  color: #4338CA;
  transform: translateX(-2px);
}

.option-btn:active:not(:disabled) {
  transform: scale(0.98);
}

.option-btn.correct {
  border-color: #10B981 !important;
  background-color: #ECFDF5 !important;
  color: #065F46 !important;
  font-weight: 700;
}

.option-btn.wrong {
  border-color: #EF4444 !important;
  background-color: #FEF2F2 !important;
  color: #991B1B !important;
  font-weight: 700;
}

/* مؤشر الخلية المستهدفة */
.target-cell {
  animation: pulse-border 1s infinite alternate;
}

@keyframes pulse-border {
  from { border: 2px solid #6366F1; box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2); }
  to { border: 2px solid #4F46E5; box-shadow: 0 0 0 6px rgba(99, 102, 241, 0.35); }
}

/* شريط التمرير المريح */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: #F1F5F9;
  border-radius: 8px;
}
::-webkit-scrollbar-thumb {
  background: #CBD5E1;
  border-radius: 8px;
}